help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Changing key bindings of printable chars


From: David Vanderschel
Subject: Re: Changing key bindings of printable chars
Date: Thu, 24 Jun 2004 23:46:16 GMT

"Paul Batt" <paul@pbatt.ch> wrote in message
2k0tudF160v27U1@uni-berlin.de">news:2k0tudF160v27U1@uni-berlin.de...
> How can I change the key binding of a single printable character key to
> another? I need to have "z" and "Z" print "y" and "Y" and vice versa

Check out keyboard-translate-table in the "Translating
Input" info node for elisp.  The keyboard-translate
function is probably what you need.  (I just made an
interesting mistake testing it:  I did
(keyboard-translate ?z ?y) first, and I could not
easilz ( :) ) do (keyboard-translate ?y ?z) because I
could no longer enter a z!  I solved the problem by
copying one from the buffer.  Word to the wise:
Compose both functions calls before executing either.)

>and I need to have RET do a double-return e.g. two
>line feeds instead of only one.  ...

I am not sure, but I think this probably requires use
of the function-key-map (same info node).  You may be
confusing ^M and ^J.

Regards,
  David V.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]