summaryrefslogtreecommitdiff
path: root/lisp/bindings.el
diff options
context:
space:
mode:
authorStefan Kangas <stefankangas@gmail.com>2022-12-23 06:30:12 +0100
committerStefan Kangas <stefankangas@gmail.com>2022-12-23 06:30:12 +0100
commit99feed933ac8b8a3384eeb40254ef2e2de4f31de (patch)
tree5f28e85fd3915dd9350375c067762d857bbdfbb5 /lisp/bindings.el
parent17bf6a829ca2fd2920c01e1aee30ab16b9c672eb (diff)
parent0754173c923a1888a1b18b4c6c5d1dc72e6cc6af (diff)
downloademacs-99feed933ac8b8a3384eeb40254ef2e2de4f31de.tar.gz
Merge from origin/emacs-29
0754173c923 ; Fix docstring 014232d3840 Eglot: eglot--servers-by-xrefed-file doesn't need to be v... bbe35c280c2 Prevent stale servers when using eglot-extend-to-xref 9bf13a3fb9e ; * src/alloc.c (Fmemory_info): Doc fix. baa33a5c054 * etc/tutorials/TUTORIAL.cn: Fix typos. (Bug#60221) 98d7f76b451 Merge branch 'emacs-29' of git.savannah.gnu.org:/srv/git/... a488a6870ac Add alias for removed font-lock function 02e046566e2 Set beginning/end-of-defun-function in treesit-major-mode... 7dea58b88db Add treesit-defun-at-point and fix c-ts-mode-indent-defun 69123d4aa4e ; Fix treesit--defuns-around 05d8310fb5d Use the new keyword ':repeat' in repeatable keymaps.
Diffstat (limited to 'lisp/bindings.el')
-rw-r--r--lisp/bindings.el13
1 files changed, 4 insertions, 9 deletions
diff --git a/lisp/bindings.el b/lisp/bindings.el
index a3f51ebb315..f2e0799f72b 100644
--- a/lisp/bindings.el
+++ b/lisp/bindings.el
@@ -1012,8 +1012,8 @@ if `inhibit-field-text-motion' is non-nil."
;; (define-key ctl-x-map "U" 'undo-only)
(defvar-keymap undo-repeat-map
:doc "Keymap to repeat undo key sequences \\`C-x u u'. Used in `repeat-mode'."
+ :repeat t
"u" #'undo)
-(put 'undo 'repeat-map 'undo-repeat-map)
(define-key global-map '[(control ??)] 'undo-redo)
(define-key global-map [?\C-\M-_] 'undo-redo)
@@ -1033,12 +1033,10 @@ if `inhibit-field-text-motion' is non-nil."
(defvar-keymap buffer-navigation-repeat-map
:doc "Keymap to repeat `next-buffer' and `previous-buffer'. Used in `repeat-mode'."
+ :repeat t
"<right>" #'next-buffer
"<left>" #'previous-buffer)
-(put 'next-buffer 'repeat-map 'buffer-navigation-repeat-map)
-(put 'previous-buffer 'repeat-map 'buffer-navigation-repeat-map)
-
(let ((map minibuffer-local-map))
(define-key map "\en" 'next-history-element)
(define-key map [next] 'next-history-element)
@@ -1111,12 +1109,11 @@ if `inhibit-field-text-motion' is non-nil."
(defvar-keymap next-error-repeat-map
:doc "Keymap to repeat `next-error' key sequences. Used in `repeat-mode'."
+ :repeat t
"n" #'next-error
"M-n" #'next-error
"p" #'previous-error
"M-p" #'previous-error)
-(put 'next-error 'repeat-map 'next-error-repeat-map)
-(put 'previous-error 'repeat-map 'next-error-repeat-map)
(defvar-keymap goto-map
:doc "Keymap for navigation commands."
@@ -1474,12 +1471,10 @@ if `inhibit-field-text-motion' is non-nil."
(defvar-keymap page-navigation-repeat-map
:doc "Keymap to repeat page navigation key sequences. Used in `repeat-mode'."
+ :repeat t
"]" #'forward-page
"[" #'backward-page)
-(put 'forward-page 'repeat-map 'page-navigation-repeat-map)
-(put 'backward-page 'repeat-map 'page-navigation-repeat-map)
-
(define-key ctl-x-map "\C-p" 'mark-page)
(define-key ctl-x-map "l" 'count-lines-page)
(define-key ctl-x-map "np" 'narrow-to-page)