Creating your own keyboard shortcuts

Keymaps are specified using the command

(kbd-map . keymaps)

Optionally, you may specify conditions which must be satisfied for the keymap to be valid using the :mode option. For instance, the command

(kbd-map (:mode in-math?) . keymaps)

specifies a list of keyboard shortcuts which will only be valid in math-mode. Each item in keymaps is of one of the following forms:

(key-combination action_1 ... action_n)

(key-combination result)

(key-combination result help-message)

In the first case, the action_i are Scheme commands associated to the string key-combination. In the second and third case, result is a string which is to be inserted in the text when the key-combination has been completed. An optional help-message may be displayed when the key-combination is finished.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".