Thread
:
emacs: <kp-enter> is not defined ....
View Single Post
paulie4
2011-02-08 , 15:43
Posts: 1 | Thanked: 0 times | Joined on Feb 2011
#
5
You can easily set any keyboard shortcut (including for a single key) in Emacs. Put one of the following in your init file (~/.emacs, ~/.emacs.el, or ~/.emacs.d/init.el) to map it to commands currently mapped to RET or C-j:
(global-set-key (kbd "<kp-enter>") 'newline)
(global-set-key (kbd "<kp-enter>") 'newline-and-indent)
You can also map it to any other key combination you currently use by finding what command is run by pressing C-h k then pressing the key combination to copy.
If you just want to test it before putting it in your init file (or using it before restarting), just run it with eval-expression, whose keyboard shortcut is M-:, i.e. meta plus colon), and put the global-set-key call in there.
Quote & Reply
|
paulie4
View Public Profile
Find all posts by paulie4