Mac tech notes
(2007–2016) ·

 

Contents:

return to top Quickies

The following notes are so brief that they don't require this introductory sentence.

deciphering mount error messages
  • mount_afp: AFPMountURL returned error -1069, errno is -1069
    → is AFP turned on on the server? (Check System Preferences > Sharing > File Sharing > Options...)
Virtual hosts don't work after upgrade to macOS Sierra
The Sierra (macOS 10.12) installer replaces your custom Apache config files with its default ones. Happily, it saved your files, appending ~previous to their filenames. Restoring them is easy:

% cd /etc/apache2 % sudo mv httpd.conf httpd.conf-installedBySierra # set aside the Apache config file installed by Sierra % sudo cp httpd.conf~previous httpd.conf # move your custom Apache config back into place % cd extra % sudo mv httpd-vhosts.conf httpd-vhosts.conf-installedBySierra # set aside Sierra's vhosts file % sudo cp httpd-vhosts.conf~previous httpd-vhosts.conf # move your vhosts file back into place % sudo apachectl restart # restart Apache

Make the ~/Library folder visible.
Open a Finder window, navigate to your home folder. Type Command-J (= View > Show View Options). Check "show library folder".
Clone a friendly login environment.
Clone a copy of your login profile from another machine on the network.

% cd ~ % sftp USER@MACHINE.local Password:····· Connected to MACHINE.local. sftp> cd sftp> get .bash_profile Fetching /Users/USER/.bash_profile to .bash_profile /Users/USER/.bash_profile 100% 1761 292.4KB/s 00:00 sftp> exit % source .bash_profile

Install XCode developer command line tools.
If you plan on building software on your Mac from the command line (via MacPorts, HomeBrew, Fink etc.), you'll need to install the XCode command line tools. To do this, launch Terminal and execute:

% xcode-select --install

In the pop-up window, click "Install". This downloads and installs a bunch of files in /Library/Developer/CommandLineTools/ . It may take 15-20 minutes to download this software. (If you click "Get XCode" instead, you'll have to endure a multi-gigabyte download from some of Apple's slower servers.)

To confirm that they installed successfully, do this:

% xcode-select -p

If this command returns a path (like /Library/Developer/CommandLineTools or /Applications/Xcode.app/Contents/Developer), then the tools are already installed. If you get a message like xcode-select: error: unable to get active developer directory..., then they're probably not installed.

Sound not coming out of speakers?
Try this: sudo kill -9 `ps ax|grep 'coreaudio[a-z]' | awk '{print $1}'`

(Courtesy of StackExchange.)

Set the Mac system clock to UTC
The Mac's "Date & Time" System Preferences doesn't offer the choice of UTC. The closest time zone in the pulldown menu is "London - United Kingdom", but that switches back and forth between Summer (daylight savings) and Winter time through the year. To set the Mac's clock to UTC, do this:
% sudo ln -sf /usr/share/zoneinfo/UTC /etc/localtime
Tell BBEdit to use a different subversion client [BBEdit 11.1]

% defaults write com.barebones.bbedit SubversionToolPathOverride \ /path/to/svn/binary

Find any file, fast! [OS X 10.10 Yosemite]
% locate somefile.txt
This is much faster than Spotlight.
What does that error code mean?? [OS X 10.10 Yosemite]
If you encounter a system error code that doesn't make sense, you can often find an explanation in the file MacErrors.h. To find where that file is located, try this:
% locate MacErrors.h /Applications/Xcode.app/Contents/..../A/Headers/MacErrors.h « really long file name! /Applications/Xcode.app/Contents/..../A/Headers/MacErrors.h /Applications/Xcode.app/Contents/..../usr/include/MacErrors.h %
That search will return a list of files with that name. Open one of them with a text editor and look there for your error code. If locate doesn't find the file, you can easily find it online with a quick Google search (save a copy for future reference). If you have the file on your system, you can write a simple script (or shell alias) to lookup error codes.

For example, when running afp I got error -5003. To find it quickly, I do this:

% grep "\-5003" `locate MacErrors.h | head -1` afpBadVersNum = -5003, /* Unknown AFP protocol version number specified */ %
(Note the escape before the hyphen in the grep command. This prevents grep from mistaking the error code for a command option.)
Play sounds in shell scripts or in a Terminal window

Use afplay. For example:

% afplay -h # (show usage) % afplay -t 2 -r .33 /System/Library/Sounds/Ping.aiff « plays "Ping" at 1/3 speed for 2 seconds

Do ls /System/Library/Sounds to see what system sounds are available. Plays mp3 files, too.

Allow the Mac to start without a keyboard attached:
System Preferences → Bluetooth → Advanced... → Uncheck the box marked "Open Bluetooth Assistant at startup when no input device is present".
To get/change the creator or type of a file:
Run /Developer/usr/bin/GetFileInfo or /Developer/usr/bin/SetFile.

return to top Using MacPorts

[Mac OS 10.12.4 "Sierra"]

Install the Macports app. Launch a terminal window, and install something — say, gnuplot:

% sudo port install gnuplot

This will take awhile, while MacPorts collects and builds all the dependencies. From time to time, Macports may report an error like this:

Warning: xcodebuild exists but failed to execute Warning: Xcode does not appear to be installed; most ports will likely fail to build.

This message may appear even after you've successfully installed the XCode command line tools. I've always ignored this error without consequence.

If MacPorts should fail to install a package, look in the log files for hints. For example:

% sudo port install gnuplot ... ---> Building gnuplot Error: org.macports.build for port gnuplot returned: command execution failed Please see the log file for port gnuplot for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_math_gnuplot/gnuplot/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port gnuplot failed %

To see what happened, open the referenced log file with your favorite text editor or log file viewer:

% bbedit /opt/local/var/macports/logs/.../gnuplot/main.log

Search the log file for the word "error" and look nearby for clues:

... :info:build Undefined symbols for architecture x86_64: :info:build "_libiconv", referenced from: :info:build _set_command in set.o :info:build _EMF_put_text in term.o :info:build _gd_iconv in term.o :info:build "_libiconv_close", referenced from: :info:build _set_command in set.o :info:build _EMF_put_text in term.o :info:build _gd_iconv in term.o :info:build "_libiconv_open", referenced from: :info:build _set_command in set.o :info:build _EMF_put_text in term.o :info:build _gd_iconv in term.o :info:build ld: symbol(s) not found for architecture x86_64 :info:build clang: error: linker command failed with exit code 1 (use -v to see invocation) :info:build make[4]: *** [gnuplot] Error 1 ...

Apparently something went wrong with the libiconv installation. Try re-installing the offending library directly:

% sudo port install libiconv

If that succeeds, then try installing the port again:

% sudo port install gnuplot

This often does the trick.

return to top Getting the at scheduler working

[Mac OS 10.10.5 "Yosemite"]

(This note was adapted from a discussion on StackExchange.)

By default, the Mac's atrun daemon is disabled, which means that the handy event scheduler at won't do anything. Here's how to get it working:

  1. Edit the atrun daemon's plist:

    % sudo vim /System/Library/LaunchDaemons/com.apple.atrun.plist

    ad change these two lines

    <key>Disabled</key> <true/>

    to

    <key>Disabled</key> <false/>

  2. Unload the old plist and reload the new one:

    % sudo launchctl unload -F /System/Library/LaunchDaemons/com.apple.atrun.plist % sudo launchctl load -F /System/Library/LaunchDaemons/com.apple.atrun.plist

  3. Test it by invoking at and giving it a simple command to execute:

    % at now echo "Hello world." ^D job 18 at Sun Dec 27 17:14:31 2015 %

    In a few moments you'll receive an email from atrun containing the output of your queued command (i.e., an email containing "Hello world." in the message body).
  4. To see what jobs are in the queue, type atq.

Caveat #1: Keep in mind that at executes its commands within the bash shell. It's always a good idea to test your command in a bash shell before entrusting it to at.

Caveat #2: If you're like most people, you probably don't use the Mac's built-in *nix mail program that at uses. But you can easily have at's emails forwarded to the email address of your choice. To do this, open (or create) the .forward file in your home directory:

% vim ~/.forward

and insert a line containing your email address:

xyz@gmail.com

You can have more than one address here — just separate them with commas.

return to top Send email from command line via Gmail SMTP in Mac OS X Yosemite

[OS 10.10.2 Yosemite]

If you want to send email directly from the Terminal command line, or from php's mail() function, you have to configure postfix to use an external SMTP server. There are many excellent tutorials and blogs out there describing how to do this, but because Apple tinkers with postfix with each major OS upgrade, these instructions can quickly become obsolete. It took me several hours to put all the pieces together and get it to work on OS X 10.10

The following instructions, gleaned and adapted from a number of blogs, tutorials, and readers' comments,[1] summarize how I got postfix to work with Gmail on OS X 10.10.2.

  1. If you don't already have a Gmail account, get one. You'll need the login credentials for that account to access Google's SMTP servers.
  2. Open a Terminal window and edit the postfix password file:

    % sudo vim /etc/postfix/sasl_passwd

    Add the following line to this file:

    smtp.gmail.com USERNAME@gmail.com:PASSWORD

    where USERNAME and PASSWORD are your Gmail login credentials. Save the file and quit.

  3. Make the password file readable only to root:

    % sudo chmod og-rw /etc/postfix/sasl_passwd

  4. Edit the main postfix config file:

    % sudo cp /etc/postfix/main.cf /etc/postfix/main.cf.orig ⇐ play safe: save a copy of the original! % sudo vim /etc/postfix/main.cf

    Add the following lines to the end of the file:

    mail_owner = _postfix setgid_group = _postdrop relayhost = smtp.gmail.com:587 # Enable SASL authentication in the Postfix SMTP client. smtp_sasl_auth_enable=yes smtp_sasl_password_maps=hash:/etc/postfix/sasl_passwd smtp_sasl_security_options= smtp_sasl_mechanism_filter = plain ⇐ OS X 10.10 Yosemite needs this line # Enable Transport Layer Security (TLS), i.e. SSL. smtp_use_tls=yes smtp_tls_security_level=encrypt tls_random_source=dev:/dev/urandom

    Save the file and quit.

  5. Restart postfix:

    % sudo postmap /etc/postfix/sasl_passwd % sudo postfix stop % sudo postfix start % sudo postfix reload

  6. Test everything by sending an email from the command line:

    % date | mail YOUREMAILADDRESS

    where YOUREMAILADDRESS is, of course, your email address. In a moment you should receive an email at that address that contains no subject, and simply the date in its body. If this works, you're done!

  7. If you don't receive an email, check the last few lines of your postfix server log:

    % tail -f /var/log/mail.log

See also this tech note: "Sending email from PHP scripts"

return to top How to install wget on a Mac

[Mac OS 10.7.5 "Lion"]

  1. Download the wget source code from ftp.gnu.org. Choose the file with the highest version number, and whose filename ends in .tar.gz (e.g., wget-1.14.tar.gz).
  2. Double-click the downloaded archived file to unarchive it into a folder. A folder named something like wget-1.14 will be created.
  3. Move the folder (e.g., wget-1.14) to wherever you keep your source files (e.g., in ~/src). From here on, we'll assume that this folder resides at ~/src/wget-1.14
  4. Type the following commands in a Terminal window:

    % cd ~/src/wget-1.14 % ./configure --with-ssl=openssl % make % sudo install % rehash

    (The --with-ssl option allows you to build wget without having to install the GNUTLS package.)

  5. Type

    % wget --help

    and you're off to the races!

return to top No audio from some websites

Problem: Sometimes I don’t hear any sound from Safari or Firefox while playing content from multimedia websites (e.g., YouTube). Curiously, sites that stream QuickTime files come through just fine; it’s just the embedded video files that don’t produce sound.

Cause: If you work with lots of sound apps (SoundHack, Audacity, etc.), one of them may have inadvertently munged some of the Mac’s core audio settings.

Fix:

  1. Open Audio MIDI Setup (/Applications/Utilities/), then check the Audio Output setting.
  2. Change the Audio Output setting to 44100.0 Hz.
  3. Quit Audio MIDI Setup.
  4. Restart the app (e.g., Firefox).

See the Apple tech article "Mac OS X: No audio from certain multimedia content" for more details.

return to top How to setup virtual hosts

[OS 10.10.2 Yosemite]

The procedure for setting up virtual hosts seems to change slightly with each update of OS X. Here's how I did it for Yosemite.

  1. Open a Terminal window and type: sudo vi /etc/extra/httpd-vhosts.conf and enter your password, if asked.
  2. Insert the following lines at the end of the file

    <VirtualHost *:80> ServerName project1 DocumentRoot /Users/yourname/Sites/project1 ErrorLog "/private/var/log/apache2/project1-localsite-error_log" CustomLog "/private/var/log/apache2/project1-localsite-access_log" common </VirtualHost>

    If you have more sites, simply add more <VirtualHost> blocks as needed, in the same format.

  3. Save and quit (type :wq).
  4. Edit your hosts file (type sudo vi /etc/hosts) and insert the following lines at the end:

    127.0.0.1 project1

    If you have more sites, just add more lines in that format. For example:

    127.0.0.1 project2

  5. Save and quit (type :wq).
  6. Restart Apache: sudo apachectl graceful
  7. Now point your browser to http://project1 and the site located at /Users/yourname/Sites/project1 will load.

return to top How to make system files and folders visible

By default, the Finder hides root-level directories (/usr, /lib, /etc, etc.,) from dialog boxes, which makes it hard to navigate there. Here’s one trick to make them accessible to the Finder’s — and every app’s — dialog boxes.

  1. In the Finder, type "shift command G" ("Go to folder").
  2. Type "/usr" (for example) and click "Go".
  3. Drag the tiny "usr" icon at the top of the window over to the sidebar.

Voilà! From now on, /usr will always be easily accessible to "open" and "save" dialog boxes in all your apps.

To make every file visible to the Finder — including those that begin with a ".", such as .htaccess or .login — issue the following command at the Terminal:

% defaults write com.apple.finder AppleShowAllFiles TRUE; killall Finder

To make those ’invisible’ files go away again, do this:

% defaults write com.apple.finder AppleShowAllFiles FALSE; killall Finder

I like to be able to turn those invisible files on and off easily, so I have a couple of aliases in my ~/.alias file:

% alias dot+ "defaults write com.apple.finder AppleShowAllFiles TRUE; killall Finder" % alias dot- "defaults write com.apple.finder AppleShowAllFiles FALSE; killall Finder"

Then it’s simply a matter of typing dot+ or dot- to toggle the visibility of those "invisible" files.

Or you could use a third-party utility such as TinkerTool.

return to top AppleScript: "Press Run to run this script"

If you write your own AppleScripts, you’ve probably seen an alert box pop up with this message when you try to run your script:

Press Run to run this script, Quit to quit.

Fix: When you save the script as an app using "Save as...", look at the save options carefully. Make sure the "Startup screen" checkbox is unchecked before saving.

Works for me.

return to top Firefox mis-renders some TrueType italics

Problem: Firefox (2.0.0.3; Mac OS 10.4.9) renders some fonts (Gentium, for example) such that italicized text overwrites the preceding character or two. The result can be an unintelligible mess (shown here in Gentium font):

gentium

Safari and IE (Mac) don’t have this problem.

Cause: Firefox seems to have difficulty in rendering TrueType fonts in italic.

Fix: Hunt down and remove any TrueType versions of the offending font in all four of the possible font folders (~/Library/Fonts, /Library/Fonts/, /Network/Library/Fonts/, and /System/Library/Fonts/ — see "Mac OS X: Font Locations and Their Purposes"). Re-install the "font suitcase" version of the font (i.e., drop the font suitcase into one of those four font folders). Restart Firefox.

return to top Windows and buttons have annoying borders

Problem:

border

Cause: You probably accidentally turned on VoiceOver, by hitting cmd-F5.

Fix: cmd-F5 toggles VoiceOver on/off. Failing that, go to System Preferences → Universal Access and turn off VoiceOver.

return to top How to install GD into PHP on Leopard

A tutorial for the easiest possible way to install GD into PHP on Leopard: Adding GD library for Mac OS X Leopard.

First, some background... Mac OS X 10.5 (Leopard) ships with PHP 5.2 installed, but without the useful GD graphics library. Most of the GD installation tutorials I found on the web involve an intimidating series of steps that require downloading a bunch of supporting libraries, compiling them, then re-compiling PHP. Although Kénior’s tutorial Adding GD Library for Mac OS X Leopard seems to have worked for many people, it never quite worked for me; after many careful tries, I kept getting Apache errors (as seen in /var/error/apache2/error_log) that prevented GD from successfully loading:

PHP Warning: PHP Startup: Unable to load dynamic library     '/usr/lib/php/extensions/no-debug-non-zts-20060613/gd.so' -     (null) in Unknown on line 0

After much hair-pulling, I finally found that wonderfully simple tutorial. It calls for simply (1) downloading a fresh PHP installation that already has GD compiled-in, and (2) using it to replace the existing PHP folder in /usr/local. I had PHP up and running with GD in about one minute.

What could be simpler?

return to top Common glyphs in ASCII and HTML (sorted by HTML code)

Glyph Description

HTML
code

HTML
entity

Latin-1
(UNIX)
decimal

Windows
decimal

Mac
decimal

Mac
keystroke

  latin uppercase S with caron       138    
  latin lowercase s with caron       154    
  non-breaking space &#160; &nbsp;   160 202 <op><sh>
¡ inverted exclamation mark &#161; &iexcl; 161 161 193 <op>1
¢ cent sign &#162; &cent; 162 162 162 <op>4
£ pound sterling sign &#163; &pound; 163 163 163 <op>3
¤ general currency sign &#164; &curren; 164 164 219 <op><sh> 2
¥ yen sign &#165; &yen; 165 165 180 <op>y
¦ broken vertical bar &#166; &brvbar; 166 166    
§ section sign &#167; &sect; 167 167 164 <op>6
¨ umlaut (diaeresis) &#168; &uml; 168 168 172 <op><sh> u
© copyright sign &#169; &copy; 169 169 169 <op>g
ª ordinal indicator, feminine &#170; &ordf; 170 170 187 <op>9
« angle quotation mark, left &#171; &laquo; 171 171 199 <op>\\
¬ not sign &#172; &not; 172 172 194 <op>l
­ soft hyphen &#173; &shy; 173 173    
® registered sign &#174; &reg; 174 174 168 <op>r
¯ macron &#175; &macr; 175 175 248 <op><sh> ,
° degree sign &#176; &deg; 176 176 161 <op><sh> 8
± plus-or-minus sign &#177; &plusmn; 177 177 177 <op><sh> =
² superscript 2 &#178; &sup2; 178 178    
³ superscript 3 &#179; &sup3; 179 179    
´ acute accent &#180; &acute; 180 180 171 <op><sh>e
µ micro sign &#181; &micro; 181 181 181 <op>m
pilcrow (paragraph sign) &#182; &para; 182 182 166 <op>7
· middle dot &#183; &middot; 183 183 225 <op><sh> 9
¸ cedilla &#184; &cedil; 184 184 252 <op><sh> z
¹ superscript 1 &#185; &sup1; 185 185 245 <op><sh>b
º ordinal indicator, masculine &#186; &ordm; 186 186 188 <op>0
» angle quotation mark, right &#187; &raquo; 187 187 200 <op><sh> \\
¼ small 1/4 fraction (one quarter) &#188; &frac14; 188 188    
½ small 1/2 fraction (one half) &#189; &frac12; 189 189    
¾ small 3/4 fraction (three quarters) &#190; &frac34; 190 190    
¿ inverted question mark &#191; &iquest; 191 191 192 <op><sh> /
À uppercase A, grave accent &#192; &Agrave; 192 192 203 <op>` A
Á uppercase A, acute accent &#193; &Aacute; 193 193 231 <op>y
 uppercase A, circumflex accent &#194; &Acirc; 194 194 229 <op><sh> m
à uppercase A, tilde &#195; &Atilde; 195 195 204 <op>n A
Ä uppercase A, diaeresis (umlaut) &#196; &Auml; 196 196 128 <op>u A
Å uppercase A, ring &#197; &Aring; 197 197 129 <op><sh> a
Æ uppercase AE diphthong (ligature) &#198; &AElig; 198 198 174 <op><sh> ’
Ç uppercase C, cedilla &#199; &Ccedil; 199 199 130 <op><sh> c
È uppercase E, grave accent &#200; &Egrave; 200 200 233 <op>` E
É uppercase E, acute accent &#201; &Eacute; 201 201 131 <op>e E
Ê uppercase E, circumflex accent &#202; &Ecirc; 202 202 230 <op>i E
Ë uppercase E, diaeresis (umlaut) &#203; &Euml; 203 203 232 <op>u E
Ì uppercase I, grave accent &#204; &Igrave; 204 204 237 <op>` I
Í uppercase I, acute accent &#205; &Iacute; 205 205 234 <op><sh> s
Î uppercase I, circumflex accent &#206; &Icirc; 206 206 235 <op><sh> d
Ï uppercase I, diaeresis (umlaut) &#207; &Iuml; 207 207 236 <op><sh> f
Ð uppercase eth, icelandic &#208; &ETH; 208 208    
Ñ uppercase N, tilde &#209; &Ntilde; 209 209 132 <op>n N
Ò uppercase O, grave accent &#210; &Ograve; 210 210 241 <op><sh> l
Ó uppercase O, acute accent &#211; &Oacute; 211 211 238 <op><sh> h
Ô uppercase O, circumflex accent &#212; &Ocirc; 212 212 239 <op><sh> j
Õ uppercase O, tilde &#213; &Otilde; 213 213 205 <op>n O
Ö uppercase O, diaeresis (umlaut) &#214; &Ouml; 214 214 133 <op>u O
× multiplication sign &#215; &times; 215 215    
Ø uppercase O, slash &#216; &Oslash; 216 216 175 <op><sh> o
Ù uppercase U, grave accent &#217; &Ugrave; 217 217 244 <op>` U
Ú uppercase U, acute accent &#218; &Uacute; 218 218 242 <op><sh>;
Û uppercase U, circumflex accent &#219; &Ucirc; 219 219 243 <op>i U
Ü uppercase U, diaeresis (umlaut) &#220; &Uuml; 220 220 134 <op>u U
Ý uppercase Y, acute accent &#221; &Yacute; 221 221    
Þ uppercase Thorn, icelandic &#222; &THORN; 222 222    
ß German eszed &#223; &szlig; 223 223 167 <op>s
à lowercase a, grave accent &#224; &agrave; 224 224 136 <op>` a
á lowercase a, acute accent &#225; &aacute; 225 225 135 <op>e a
â lowercase a, circumflex accent &#226; &acirc; 226 226 137 <op>i a
ã lowercase a, tilde &#227; &atilde; 227 227 139 <op>n a
ä lowercase a, diaeresis (umlaut) &#228; &auml; 228 228 138 <op>u a
å lowercase a, ring &#229; &aring; 229 229 140 <op>a
æ lowercase ae diphthong (ligature) &#230; &aelig; 230 230 190 <op>’
ç lowercase c, cedilla &#231; &ccedil; 231 231 141 <op>c
è lowercase e, grave accent &#232; &egrave; 232 232 143 <op>` e
é lowercase e, acute accent &#233; &eacute; 233 233 142 <op>e E
ê lowercase e, circumflex accent &#234; &ecirc; 234 234 144 <op>i e
ë lowercase e, diaeresis (umlaut) &#235; &euml; 235 235 145 <op>u e
ì lowercase i, grave accent &#236; &igrave; 236 236 147 <op>` i
í lowercase i, acute accent &#237; &iacute; 237 237 146 <op>e i
î lowercase i, circumflex accent &#238; &icirc; 238 238 148 <op>i i
ï lowercase i, diaeresis (umlaut) &#239; &iuml; 239 239 149 <op>u i
ð lowercase eth, icelandic &#240; &eth; 240 240    
ñ lowercase n, tilde &#241; &ntilde; 241 241 150 <op>n n
ò lowercase o, grave accent &#242; &ograve; 242 242 152 <op>` o
ó lowercase o, acute accent &#243; &oacute; 243 243 151 <op>e o
ô lowercase o, circumflex accent &#244; &ocirc; 244 244 153 <op>i o
õ lowercase o, tilde &#245; &otilde; 245 245 155 <op>n o
ö lowercase o, diaeresis (umlaut) &#246; &ouml; 246 246 154 <op>u o
÷ divide sign &#247; &divide; 247 247 214 <op>/
ø lowercase o, slash &#248; &oslash; 248 248 191 <op>o
ù lowercase u, grave accent &#249; &ugrave; 249 249 157 <op>` u
ú lowercase u, acute accent &#250; &uacute; 250 250 156 <op>e u
û lowercase u, circumflex accent &#251; &ucirc; 251 251 158 <op>i u
ü lowercase u, diaeresis (umlaut) &#252; &uuml; 252 252 159 <op>u u
ý lowercase y, acute accent &#253; &yacute; 253 253    
þ lowercase thorn, icelandic &#254; &thorn; 254 254    
ÿ lowercase y, diaeresis (umlaut) &#255; &yuml; 255 255 216 <op>u y
Œ latin uppercase ligature OE &#338; &OElig;   140 206 <op><sh>q
œ latin lowercase ligature oe &#339; &oelig;   156 207 <op>q
Ÿ latin uppercase Y with diaeresis &#376; &Yuml;   159 217 <op>u Y
ƒ latin small f with hook (function or florin) &#402; &fnof;   131 196 <op>f
ˆ modifier letter circumflex accent &#710; &circ;   136 246 <op><sh>i
ˇ caron &#711;       255 <op><sh>t
˘ breve &#728;       249 <op><sh>.
˙ dot above &#729;       250 <op>h
˚ ring above &#730;       251 <op>k
˛ ogonek &#731;       254 <op>x
˜ small tilde &#732; &tilde;   152 247 <op><sh>n
˝ double acute accent &#733;       253 <op><sh>g
Δ greek uppercase delta &#916; &Delta;     198 <op>j
Ω greek uppercase omega &#937; &Omega;     189 <op>z
π greek lowercase pi &#960; &pi;     185 <op>p
en dash &#8211; &ndash;   150 208 <op>-
em dash &#8212; &mdash;   151 209 <op><sh>-
left single quotation mark &#8216; &lsquo;   145 212 <op>]
right single quotation mark &#8217; &rsquo;   146 213 <op><sh>]
single low-9 quotation mark &#8218; &sbquo;   130 226 <op><sh>0
left double quotation mark &#8220; &ldquo;   147 210 <op>[
right double quotation mark &#8221; &rdquo;   148 211 <op><sh>[
double low-9 quotation mark &#8222; &bdquo;   132 227 <op><sh>w
dagger &#8224; &dagger;   134 160 <op>t
double dagger &#8225; &Dagger;   135 224 <op><sh>7
bullet (black small circle) &#8226; &bull;   149 165 <op>8
horizontal ellipsis (three dot leader) &#8230; &hellip;   133 201 <op>;
per mille sign &#8240; &permil;   137 228 <op><sh>r
single left-pointing angle quotation mark &#8249; &lsaquo;   139 220 <op><sh>3
single right-pointing angle quotation mark &#8250; &rsaquo;   155 221 <op><sh>4
fraction slash &#8260; &frasl;     218 <op><sh>1
trade mark sign &#8482; &trade;   153 170 <op>2
trade mark sign &#8482; &trade;        
small 1/3 fraction (one third) &#8531;          
small 2/3 fraction (two thirds) &#8532;          
small 2/3 fraction (two thirds) &#8532;          
small 1/5 fraction (one fifth) &#8533;          
small 2/5 fraction (two fifths) &#8534;          
small 3/5 fraction (three fifths) &#8535;          
small 4/5 fraction (four fifths) &#8536;          
small 1/6 fraction (one sixth) &#8537;          
small 5/6 fraction (five sixths) &#8538;          
small 1/8 fraction (one eighth) &#8539;          
small 3/8 fraction (three eighths) &#8540;          
small 5/8 fraction (five eighths) &#8541;          
small 7/8 fraction (seven eighths) &#8542;          
partial differential (del) &#8706; &part;     182 <op>d
n-ary product (product sign; greek large pi) &#8719; &prod;     184 <op><sh>p
n-ary summation (greek large sigma) &#8721; &sum;     183 <op>w
square root (radical sign) &#8730; &radic;     195 <op>v
infinity &#8734; &infin;     176 <op>5
integral &#8747; &int;     186 <op>b
almost equal to (asymptotic to) &#8776; &asymp;     197 <op>x
not equal to &#8800; &ne;     173 <op>=
less-than or equal to &#8804; &le;     178 <op>,
greater-than or equal to &#8805; &ge;     179 <op>.
lozenge &#9674; &loz;     215 <op><sh>v
Apple logo &#63743;       240 <op><sh>k
ligature fi &#64257;       222 <op><sh>5
ligature fl &#64258;       223 <op><sh>6

Sources:

  • Griswold, Ralph E. and Madge T. Griswold, The Icon Programming Language, 3rd ed. Peer to Peer, 1997, as quoted in www.cs.arizona.edu by Ralph Griswold, University of Arizona.
  • "Character entity references in HTML 4" (Section 24 of HTML 4.01 Specification: W3C Recommendation), by the World Wide Web Consortium; 1999.12.24; www.w3.org.
  • "ASCII Extended Character Set, Macintosh", by Dawn Rorvik, Evergreen State College; 2003.05.20; www.evergreen.edu.

See also:

return to top Common glyphs in ASCII and HTML (sorted by Mac code)

Glyph Description

HTML
code

HTML
entity

Latin-1
(UNIX)
decimal

Windows
decimal

Mac
decimal

Mac
keystroke

  latin uppercase S with caron       138    
  latin lowercase s with caron       154    
¦ broken vertical bar &#166; &brvbar; 166 166    
­ soft hyphen &#173; &shy; 173 173    
² superscript 2 &#178; &sup2; 178 178    
³ superscript 3 &#179; &sup3; 179 179    
¼ small 1/4 fraction (one quarter) &#188; &frac14; 188 188    
½ small 1/2 fraction (one half) &#189; &frac12; 189 189    
¾ small 3/4 fraction (three quarters) &#190; &frac34; 190 190    
Ð uppercase eth, icelandic &#208; &ETH; 208 208    
× multiplication sign &#215; &times; 215 215    
Ý uppercase Y, acute accent &#221; &Yacute; 221 221    
Þ uppercase Thorn, icelandic &#222; &THORN; 222 222    
ð lowercase eth, icelandic &#240; &eth; 240 240    
ý lowercase y, acute accent &#253; &yacute; 253 253    
þ lowercase thorn, icelandic &#254; &thorn; 254 254    
Ä uppercase A, diaeresis (umlaut) &#196; &Auml; 196 196 128 <op>u A
Å uppercase A, ring &#197; &Aring; 197 197 129 <op><sh> a
Ç uppercase C, cedilla &#199; &Ccedil; 199 199 130 <op><sh> c
É uppercase E, acute accent &#201; &Eacute; 201 201 131 <op>e E
Ñ uppercase N, tilde &#209; &Ntilde; 209 209 132 <op>n N
Ö uppercase O, diaeresis (umlaut) &#214; &Ouml; 214 214 133 <op>u O
Ü uppercase U, diaeresis (umlaut) &#220; &Uuml; 220 220 134 <op>u U
á lowercase a, acute accent &#225; &aacute; 225 225 135 <op>e a
à lowercase a, grave accent &#224; &agrave; 224 224 136 <op>` a
â lowercase a, circumflex accent &#226; &acirc; 226 226 137 <op>i a
ä lowercase a, diaeresis (umlaut) &#228; &auml; 228 228 138 <op>u a
ã lowercase a, tilde &#227; &atilde; 227 227 139 <op>n a
å lowercase a, ring &#229; &aring; 229 229 140 <op>a
ç lowercase c, cedilla &#231; &ccedil; 231 231 141 <op>c
é lowercase e, acute accent &#233; &eacute; 233 233 142 <op>e E
è lowercase e, grave accent &#232; &egrave; 232 232 143 <op>` e
ê lowercase e, circumflex accent &#234; &ecirc; 234 234 144 <op>i e
ë lowercase e, diaeresis (umlaut) &#235; &euml; 235 235 145 <op>u e
í lowercase i, acute accent &#237; &iacute; 237 237 146 <op>e i
ì lowercase i, grave accent &#236; &igrave; 236 236 147 <op>` i
î lowercase i, circumflex accent &#238; &icirc; 238 238 148 <op>i i
ï lowercase i, diaeresis (umlaut) &#239; &iuml; 239 239 149 <op>u i
ñ lowercase n, tilde &#241; &ntilde; 241 241 150 <op>n n
ó lowercase o, acute accent &#243; &oacute; 243 243 151 <op>e o
ò lowercase o, grave accent &#242; &ograve; 242 242 152 <op>` o
ô lowercase o, circumflex accent &#244; &ocirc; 244 244 153 <op>i o
ö lowercase o, diaeresis (umlaut) &#246; &ouml; 246 246 154 <op>u o
õ lowercase o, tilde &#245; &otilde; 245 245 155 <op>n o
ú lowercase u, acute accent &#250; &uacute; 250 250 156 <op>e u
ù lowercase u, grave accent &#249; &ugrave; 249 249 157 <op>` u
û lowercase u, circumflex accent &#251; &ucirc; 251 251 158 <op>i u
ü lowercase u, diaeresis (umlaut) &#252; &uuml; 252 252 159 <op>u u
dagger &#8224; &dagger;   134 160 <op>t
° degree sign &#176; &deg; 176 176 161 <op><sh> 8
¢ cent sign &#162; &cent; 162 162 162 <op>4
£ pound sterling sign &#163; &pound; 163 163 163 <op>3
§ section sign &#167; &sect; 167 167 164 <op>6
bullet (black small circle) &#8226; &bull;   149 165 <op>8
pilcrow (paragraph sign) &#182; &para; 182 182 166 <op>7
ß German eszed &#223; &szlig; 223 223 167 <op>s
® registered sign &#174; &reg; 174 174 168 <op>r
© copyright sign &#169; &copy; 169 169 169 <op>g
trade mark sign &#8482; &trade;   153 170 <op>2
´ acute accent &#180; &acute; 180 180 171 <op><sh>e
¨ umlaut (diaeresis) &#168; &uml; 168 168 172 <op><sh> u
not equal to &#8800; &ne;     173 <op>=
Æ uppercase AE diphthong (ligature) &#198; &AElig; 198 198 174 <op><sh> ’
Ø uppercase O, slash &#216; &Oslash; 216 216 175 <op><sh> o
infinity &#8734; &infin;     176 <op>5
± plus-or-minus sign &#177; &plusmn; 177 177 177 <op><sh> =
less-than or equal to &#8804; &le;     178 <op>,
greater-than or equal to &#8805; &ge;     179 <op>.
¥ yen sign &#165; &yen; 165 165 180 <op>y
µ micro sign &#181; &micro; 181 181 181 <op>m
partial differential (del) &#8706; &part;     182 <op>d
n-ary summation (greek large sigma) &#8721; &sum;     183 <op>w
n-ary product (product sign; greek large pi) &#8719; &prod;     184 <op><sh>p
π greek lowercase pi &#960; &pi;     185 <op>p
integral &#8747; &int;     186 <op>b
ª ordinal indicator, feminine &#170; &ordf; 170 170 187 <op>9
º ordinal indicator, masculine &#186; &ordm; 186 186 188 <op>0
Ω greek uppercase omega &#937; &Omega;     189 <op>z
æ lowercase ae diphthong (ligature) &#230; &aelig; 230 230 190 <op>’
ø lowercase o, slash &#248; &oslash; 248 248 191 <op>o
¿ inverted question mark &#191; &iquest; 191 191 192 <op><sh> /
¡ inverted exclamation mark &#161; &iexcl; 161 161 193 <op>1
¬ not sign &#172; &not; 172 172 194 <op>l
square root (radical sign) &#8730; &radic;     195 <op>v
ƒ latin small f with hook (function or florin) &#402; &fnof;   131 196 <op>f
almost equal to (asymptotic to) &#8776; &asymp;     197 <op>x
Δ greek uppercase delta &#916; &Delta;     198 <op>j
« angle quotation mark, left &#171; &laquo; 171 171 199 <op>\\
» angle quotation mark, right &#187; &raquo; 187 187 200 <op><sh> \\
horizontal ellipsis (three dot leader) &#8230; &hellip;   133 201 <op>;
  non-breaking space &#160; &nbsp;   160 202 <op><sh>
À uppercase A, grave accent &#192; &Agrave; 192 192 203 <op>` A
à uppercase A, tilde &#195; &Atilde; 195 195 204 <op>n A
Õ uppercase O, tilde &#213; &Otilde; 213 213 205 <op>n O
Œ latin uppercase ligature OE &#338; &OElig;   140 206 <op><sh>q
œ latin lowercase ligature oe &#339; &oelig;   156 207 <op>q
en dash &#8211; &ndash;   150 208 <op>-
em dash &#8212; &mdash;   151 209 <op><sh>-
left double quotation mark &#8220; &ldquo;   147 210 <op>[
right double quotation mark &#8221; &rdquo;   148 211 <op><sh>[
left single quotation mark &#8216; &lsquo;   145 212 <op>]
right single quotation mark &#8217; &rsquo;   146 213 <op><sh>]
÷ divide sign &#247; &divide; 247 247 214 <op>/
lozenge &#9674; &loz;     215 <op><sh>v
ÿ lowercase y, diaeresis (umlaut) &#255; &yuml; 255 255 216 <op>u y
Ÿ latin uppercase Y with diaeresis &#376; &Yuml;   159 217 <op>u Y
fraction slash &#8260; &frasl;     218 <op><sh>1
¤ general currency sign &#164; &curren; 164 164 219 <op><sh> 2
single left-pointing angle quotation mark &#8249; &lsaquo;   139 220 <op><sh>3
single right-pointing angle quotation mark &#8250; &rsaquo;   155 221 <op><sh>4
ligature fi &#64257;       222 <op><sh>5
ligature fl &#64258;       223 <op><sh>6
double dagger &#8225; &Dagger;   135 224 <op><sh>7
· middle dot &#183; &middot; 183 183 225 <op><sh> 9
single low-9 quotation mark &#8218; &sbquo;   130 226 <op><sh>0
double low-9 quotation mark &#8222; &bdquo;   132 227 <op><sh>w
per mille sign &#8240; &permil;   137 228 <op><sh>r
 uppercase A, circumflex accent &#194; &Acirc; 194 194 229 <op><sh> m
Ê uppercase E, circumflex accent &#202; &Ecirc; 202 202 230 <op>i E
Á uppercase A, acute accent &#193; &Aacute; 193 193 231 <op>y
Ë uppercase E, diaeresis (umlaut) &#203; &Euml; 203 203 232 <op>u E
È uppercase E, grave accent &#200; &Egrave; 200 200 233 <op>` E
Í uppercase I, acute accent &#205; &Iacute; 205 205 234 <op><sh> s
Î uppercase I, circumflex accent &#206; &Icirc; 206 206 235 <op><sh> d
Ï uppercase I, diaeresis (umlaut) &#207; &Iuml; 207 207 236 <op><sh> f
Ì uppercase I, grave accent &#204; &Igrave; 204 204 237 <op>` I
Ó uppercase O, acute accent &#211; &Oacute; 211 211 238 <op><sh> h
Ô uppercase O, circumflex accent &#212; &Ocirc; 212 212 239 <op><sh> j
Apple logo &#63743;       240 <op><sh>k
Ò uppercase O, grave accent &#210; &Ograve; 210 210 241 <op><sh> l
Ú uppercase U, acute accent &#218; &Uacute; 218 218 242 <op><sh>;
Û uppercase U, circumflex accent &#219; &Ucirc; 219 219 243 <op>i U
Ù uppercase U, grave accent &#217; &Ugrave; 217 217 244 <op>` U
¹ superscript 1 &#185; &sup1; 185 185 245 <op><sh>b
ˆ modifier letter circumflex accent &#710; &circ;   136 246 <op><sh>i
˜ small tilde &#732; &tilde;   152 247 <op><sh>n
¯ macron &#175; &macr; 175 175 248 <op><sh> ,
˘ breve &#728;       249 <op><sh>.
˙ dot above &#729;       250 <op>h
˚ ring above &#730;       251 <op>k
¸ cedilla &#184; &cedil; 184 184 252 <op><sh> z
˝ double acute accent &#733;       253 <op><sh>g
˛ ogonek &#731;       254 <op>x
ˇ caron &#711;       255 <op><sh>t
small 1/3 fraction (one third) &#8531;          
small 2/3 fraction (two thirds) &#8532;          
small 2/3 fraction (two thirds) &#8532;          
small 1/5 fraction (one fifth) &#8533;          
small 2/5 fraction (two fifths) &#8534;          
small 3/5 fraction (three fifths) &#8535;          
small 4/5 fraction (four fifths) &#8536;          
small 1/6 fraction (one sixth) &#8537;          
small 5/6 fraction (five sixths) &#8538;          
small 1/8 fraction (one eighth) &#8539;          
small 3/8 fraction (three eighths) &#8540;          
small 5/8 fraction (five eighths) &#8541;          
small 7/8 fraction (seven eighths) &#8542;          

Sources:

  • Griswold, Ralph E. and Madge T. Griswold, The Icon Programming Language, 3rd ed. Peer to Peer, 1997, as quoted in www.cs.arizona.edu by Ralph Griswold, University of Arizona.
  • "Character entity references in HTML 4" (Section 24 of HTML 4.01 Specification: W3C Recommendation), by the World Wide Web Consortium; 1999.12.24; www.w3.org.
  • "ASCII Extended Character Set, Macintosh", by Dawn Rorvik, Evergreen State College; 2003.05.20; www.evergreen.edu.

See also: