remap emacs key
I would like to remap a key in emacs, for example {
and i would it to trigger usual event.
Example, i remapped alt
+ (
to get {
and i would like, when i use a plugin like autopair
to give me the associated }
.
I tried this :
(global-set-key [(alt \()] ( lambda () (interactive) (insert "{") ))
It inserts {
correctly but does not trigger autopair
hooks.
Is there a way开发者_开发技巧 to achieve it ?
Try (not tested):
(define-key key-translation-map (kbd "M-(") (kbd "{"))
精彩评论