Important: The information in this document is obsolete and should not be used for new development.
The U.S. Keyboard-Layout ('KCHR') Resource
The U.S. system software keyboard-layout resource (resource type'KCHR'
, ID = 0) is included with every Macintosh system. It implements the Standard Roman character set shown in Figure A-1 on page A-5. The structure of the keyboard-layout resource is documented in the appendix "Keyboard Resources" in this book. This section describes in general how the U.S.'KCHR'
resource handles key combinations and dead keys.The U.S. system software's keyboard-layout resource makes it possible to enter accented forms in the Standard Roman character set with dead keys, designated keys or modifier-plus-key combinations that produce no immediate effect when pressed but instead affect the character or characters produced by the next keys typed, called completer keys. Users can enter all the accented forms in the Standard Roman character set with dead keys. For example, pressing Option-E on the U.S. keyboard produces nothing (no event is posted), but subsequently typing "e" produces "é".
The U.S. keyboard-layout resource provides the following key-combination features for consistency:
- Note
- Other keyboard layouts may produce accented characters in other ways. On the French keyboard (
'KCHR'
resource ID = 1), for example, pressing Option-E directly produces "é".
A no-match character (also called a default completion character) is the character that is produced when the keystroke following a dead key is either a space or a key for a character that cannot take the accent corresponding to the dead key. In system software versions 7.0 and later, default completion characters are "real" accent characters instead of low-ASCII approximations.
- Because the Shift key is ignored if the Command key is pressed, the Caps Lock key is also ignored if the Command key is pressed.
- Handling of the Option-Shift and Option-Caps Lock key combinations is based on the following principles:
- If either the Option or the Option-Shift key combination produces a letter, then the Option-Caps Lock key combination produces the same character as the Option, not the Option-Shift, key combination.
- If the Option key combination is a dead key for a particular accent, then the Option-Shift key combination produces the accent directly.