mirror of
https://github.com/masscollaborationlabs/emacs.git
synced 2025-07-07 20:59:37 +00:00
Add bind-keys* macro
This commit is contained in:
parent
2d67e1dca1
commit
c4ebcaa953
1 changed files with 12 additions and 0 deletions
|
@ -73,6 +73,14 @@
|
||||||
;; Additionally, :prefix-docstring can be specified to set
|
;; Additionally, :prefix-docstring can be specified to set
|
||||||
;; documentation of created :prefix-map variable.
|
;; documentation of created :prefix-map variable.
|
||||||
;;
|
;;
|
||||||
|
;; To bind multiple keys in a `bind-key*' way (to be sure that your bindings
|
||||||
|
;; will not be overridden by other modes), you may use `bind-keys*' macro:
|
||||||
|
;;
|
||||||
|
;; (bind-keys*
|
||||||
|
;; ("C-o" . other-window)
|
||||||
|
;; ("C-M-n" . forward-page)
|
||||||
|
;; ("C-M-p" . backward-page))
|
||||||
|
;;
|
||||||
;; After Emacs loads, you can see a summary of all your personal keybindings
|
;; After Emacs loads, you can see a summary of all your personal keybindings
|
||||||
;; currently in effect with this command:
|
;; currently in effect with this command:
|
||||||
;;
|
;;
|
||||||
|
@ -194,6 +202,10 @@ function symbol (unquoted)."
|
||||||
,(or prefix-map map)))
|
,(or prefix-map map)))
|
||||||
key-bindings))))
|
key-bindings))))
|
||||||
|
|
||||||
|
(defmacro bind-keys* (&rest args)
|
||||||
|
`(bind-keys :map override-global-map
|
||||||
|
,@args))
|
||||||
|
|
||||||
(defun get-binding-description (elem)
|
(defun get-binding-description (elem)
|
||||||
(cond
|
(cond
|
||||||
((listp elem)
|
((listp elem)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue