aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/emulation
diff options
context:
space:
mode:
authorEli Zaretskii2019-03-20 11:21:54 +0200
committerEli Zaretskii2019-03-20 11:21:54 +0200
commitf13d97b4de02586cce49909aa2f3f51fcb5daa5f (patch)
treea467b0e89bd82d81a1ece2f94b69872b6312c28e /lisp/emulation
parent047c1b19353ff58d8cd45935c7b44c911b70e312 (diff)
downloademacs-f13d97b4de02586cce49909aa2f3f51fcb5daa5f.tar.gz
emacs-f13d97b4de02586cce49909aa2f3f51fcb5daa5f.zip
Fix defining keyboard macros in CUA mode
* lisp/emulation/cua-base.el (cua--prefix-override-replay): Push the key to replace wrapped in '(no-record . KEY)', so that it doesn't get recorded more than once. (Bug#34901) * src/keyboard.c (read_char): Handle the '(no-record . KEY)' event by substituting KEY for it. (syms_of_keyboard) <no-record>: New DEFSYM. <unread-command-events>: Update the doc string. * doc/lispref/commands.texi (Event Input Misc): Document the '(no-record . EVENT)' form.
Diffstat (limited to 'lisp/emulation')
-rw-r--r--lisp/emulation/cua-base.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/emulation/cua-base.el b/lisp/emulation/cua-base.el
index 43e0956ea83..302ef123865 100644
--- a/lisp/emulation/cua-base.el
+++ b/lisp/emulation/cua-base.el
@@ -710,7 +710,8 @@ a cons (TYPE . COLOR), then both properties are affected."
710 ;; C-x binding after the first C-x C-x was rewritten to just C-x). 710 ;; C-x binding after the first C-x C-x was rewritten to just C-x).
711 (prefix-command-preserve-state) 711 (prefix-command-preserve-state)
712 ;; Push the key back on the event queue 712 ;; Push the key back on the event queue
713 (setq unread-command-events (cons key unread-command-events)))) 713 (setq unread-command-events (cons (cons 'no-record key)
714 unread-command-events))))
714 715
715(defun cua--prefix-override-handler () 716(defun cua--prefix-override-handler ()
716 "Start timer waiting for prefix key to be followed by another key. 717 "Start timer waiting for prefix key to be followed by another key.