/[emacs]/emacs/man/faq.texi
ViewVC logotype

Diff of /emacs/man/faq.texi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.66 by rms, Thu Aug 11 19:49:52 2005 UTC revision 1.67 by rms, Thu Aug 18 15:02:16 2005 UTC
# Line 4637  Good question! Line 4637  Good question!
4637  @cindex Keys, swapping  @cindex Keys, swapping
4638  @cindex @code{keyboard-translate}  @cindex @code{keyboard-translate}
4639    
4640  In Emacs 19, you can swap two keys (or key sequences) by using the  You can swap two keys (or key sequences) by using the
4641  @code{keyboard-translate} function.  For example, to turn @kbd{C-h} into  @code{keyboard-translate} function.  For example, to turn @kbd{C-h}
4642  @key{DEL} and @key{DEL} to @kbd{C-h}, use  into @key{DEL} and @key{DEL} to @kbd{C-h}, use
4643    
4644  @lisp  @lisp
4645  (keyboard-translate ?\C-h ?\C-?)  ; translate `C-h' to DEL  (keyboard-translate ?\C-h ?\C-?)  ; translate `C-h' to DEL
# Line 4651  The first key sequence of the pair after Line 4651  The first key sequence of the pair after
4651  produced by the keyboard; the second, what is matched for in the  produced by the keyboard; the second, what is matched for in the
4652  keymaps.  keymaps.
4653    
4654    However, in the specific case of @kbd{C-h} and @key{DEL}, you should
4655    toggle @code{normal-erase-is-backspace-mode} instead of calling
4656    @code{keyboard-translate}.  @inforef{DEL Does Not Delete, DEL Does Not Delete,
4657    emacs}.
4658    
4659  Keyboard translations are not the same as key bindings in keymaps.  Keyboard translations are not the same as key bindings in keymaps.
4660  Emacs contains numerous keymaps that apply in different situations, but  Emacs contains numerous keymaps that apply in different situations, but
4661  there is only one set of keyboard translations, and it applies to every  there is only one set of keyboard translations, and it applies to every
# Line 4659  take place at the lowest level of input Line 4664  take place at the lowest level of input
4664  looked up in keymaps contain the characters that result from keyboard  looked up in keymaps contain the characters that result from keyboard
4665  translation.  translation.
4666    
 @inforef{Keyboard Translations, Keyboard Translations, emacs}.  
   
4667  @node Producing C-XXX with the keyboard, No Meta key, Swapping keys, Key bindings  @node Producing C-XXX with the keyboard, No Meta key, Swapping keys, Key bindings
4668  @section How do I produce C-XXX with my keyboard?  @section How do I produce C-XXX with my keyboard?
4669  @cindex Producing control characters  @cindex Producing control characters

Legend:
Removed from v.1.66  
changed lines
  Added in v.1.67

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26