Jump to: Navigation.

U.S. custom – A Keyboard Layout with a Compose Key for Mac

On this page:


New release, swapped compose (now §) and option deadkey (now ±, that is, +§): uscustom.2012-08-30.zip.
New release, with compose key now additionally mapped to +^+F13: uscustom.2012-08-28.zip.
New release, now with a compose key: uscustom.2012-08-24.zip.
Initial release: uscustom.2010-08-20.zip!


The U.S. custom keyboard layout is for Mac OS X computers (I don’t exclude the possibility that there might be future releases for other systems, but currently I don’t have the knowledge). It has three main purposes:

  1. Have a compose key on Mac OS.
  2. Access option combos even when the physical option modifier is used for something else (e.g. as Meta/Alt in a terminal).
  3. Assign something useful (U.S. Extended) to capslock.

This keyboard layout is intended to be as unintrusive as Apple’s normal U.S. keyboard layout, but at the same time, even more powerful than Apple’s U.S. Extended keyboard layout – especially for developers and occasional IPA users.

I have developed this keyboard layout for my personal use. It is my default keyboard layout. Perhaps someone else might find it useful, too. Especially users of Apple’s U.S. Extended keyboard layout might find this keyboard layout easy to use.

Compose key on Mac OS X

This keyboard layout implements the compose key on Mac OS X by using a keyboard layout (duh). There is another possibility that has been pointed out in a number of places: Customizing the Cocoa text system, that is, editing the file Library/KeyBindings/DefaultKeyBinding.dict (see Cocoa Text System by Jacob Rus, Compose key for OSX by Bob Kåres, Setting up a real compose key on Mac OS X by sam, or Mac OS X Keybinding Key Syntax by Xah Lee).

Both methods have their pros and cons:

Getting a compose key by modifying DefaultKeyBinding.dict works across different keyboard layouts, just as on Linux. However, it is limited to Cocoa applications. Customization is more straightforeward and better documented on the net. However, there is no UI for changing such a compose key.

Getting a compose key by a keyboard layout like U.S. custom works all over the OS. Its behaviour slightly differs from what you are used to on Linux. There is a visual feedback until the compose sequence is completed. I believe this is very helpful. However, when you interrupt the compose sequence (for instance, by hitting Backspace or by typing a character that does not fit in the compose sequence), the visual feedback is really typed.


  1. Download and open uscustom.2012-08-30.zip (alternatively, go to Browse U.S. custom keyboard layout Files on SourceForge.net and choose a release).
  2. Move the files UScustom.keylayout and UScustom.icns to either one of the following folders:
    • /Library/Keyboard Layouts/
    • ~/Library/Keyboard Layouts/
  3. Activate U.S. custom in the Input Sources tab of the Language & Text preference pane (in System Preferences), and then select it from the Input menu in the menu bar – its icon is a U.S. flag with a tiny C for «custom» or «compose»: U.S. custom icon.

Where is the compose key?

The compose key is mapped to two different keys:


Normal mode (without capslock)

No modifiers

The only difference from Apple’s U.S. keyboard layout is the compose key . The compose combos have been mostly copied from an Ubuntu 12.04 /usr/share/X11/locale/en_US.UTF-8/Compose (dropping combos that require which are not present on the U.S. keyboard layout and adding some).

no modifiers


The only difference from Apple’s U.S. keyboard layout is the option deadkey which allows typing characters that normally require the option modifier . This is especially useful for typing on Terminal.app where you will prefer the option modifier to behave like Meta .

Example: Suppose you want to type ‹ß› (U+00DF, LATIN SMALL LETTER SHARP S) in Emacs. Normally, you would press +s. In Emacs, you cannot do this because you have set the option modifier to behave like a Meta, so when you press +s, Emacs understands +s which does not produce ‹ß› at all, but the command center-line. This keyboard layout provides the additional option deadkey which will produce a deadkey state that duplicates the effects of the option modifier. If you hit the option deadkey , release it, and then hit s, you will get ‹ß› – even in Emacs!



No difference from Apple’s U.S. keyboard layout – this is the same layout you get after having pressed the option deadkey :


Option + Shift

No difference from Apple’s U.S. keyboard layout – this is the same layout you get after having pressed the option deadkey and then using shift:


Capslock mode

The capslock mode is similar to Apple’s U.S. Extended keyboard layout.

Capslock (no other modifiers)

Without additional modifiers, the layout is the same as the normal U.S. keyboard layout except for the compose key and a few regular keys behave like deadkeys. These deadkeys produce common accented keys, in a similar fashion like the US-International keyboard layout. I have deliberately decided to use other keys than the ones of the US-International keyboard. The US-International deadkeys have the advantage that they are mnemonic, but they have the disadvantage that they are likely to interfere with regular typing.

Example: Pressing the the US-International deadkey ' followed by e produces ‹é› (U+00E9, LATIN SMALL LETTER E WITH ACUTE), but when you wish to type ‹class='e'›, that deadkey interferes and converts the output into ‹class=é'›.

In order to avoid this problem, I have chosen deadkeys that are not normally followed by Latin letters. Of course, the problem persists, but I hope it will occur more seldom. The deadkeys I have chosen ar ; for umlaut and caron, ` for grave, , for circumflex and ] for acute:


Capslock, Shift

The only difference from Apple’s U.S. keyboard layout is the option deadkey :

capslock, shift

Capslock, Option

While this is identical to Apple’s U.S. Extended keyboard layout (except for the ² deadkey), a significantly higher number of combos has been added. Also, they can be combined with each other. For instance, when you first hit the macron deadkey ˉ (+A) and then the acute deadkey ´ (+E), the next character will have both a macron and an acute.

Hitting Space after any diacritcs deadkey produces the combining character of that diacritic. Hitting +Space produces the corresponding spacing character.

capslock, option

Capslock, Option + Shift

While this is identical to Apple’s U.S. Extended keyboard layout (except for the ³ deadkey), the multiple purpose deadkeys and ʔ have been added many additional characters.

Example: Pressing the multiple purpose deadkey ʔ (++.) followed by v (alternatively, the option deadkey followed by +. followed by v) will produce ‹ʋ› (U+028B, LATIN SMALL LETTER V WITH HOOK).

Another example: Pressing the multiple purpose deadkey (++;) followed by ++' (alternatively, the option deadkey followed by +; followed by the option deadkey followed by +') will produce ‹ˌ› (U+02CC, MODIFIER LETTER LOW VERTICAL LINE).

capslock, option+shift

At the moment, I have no overview of all the characters that can be produced by the multiple purpose deadkeys , ʔ, ², and ³. I suggest using Apple’s keyboard viewer. As a rule of thumb, produces alternate forms, ʔ produces alternate forms with hooks, and ³ produces some arrows.


You can reach me through e-mail at: j_maREMch_OVEwuTHISst@sharedTEXT-files.de.

You may also want to check out my sourceforge user web: j. ‘mach’ wust’s sourceforge user web.