Function: windmove-install-defaults
windmove-install-defaults is a byte-compiled function defined in
windmove.el.gz.
Signature
(windmove-install-defaults PREFIX MODIFIERS ALIST &optional UNINSTALL)
Documentation
Install keys as specified by ALIST.
Every element of ALIST has the form (FN KEY), where KEY is appended to MODIFIERS, adding PREFIX to the beginning, before installing the key. Previous bindings of FN are unbound. If UNINSTALL is non-nil, just remove the keys from ALIST.
Source Code
;; Defined in /usr/src/emacs/lisp/windmove.el.gz
(defun windmove-install-defaults (prefix modifiers alist &optional uninstall)
"Install keys as specified by ALIST.
Every element of ALIST has the form (FN KEY), where KEY is
appended to MODIFIERS, adding PREFIX to the beginning, before
installing the key. Previous bindings of FN are unbound.
If UNINSTALL is non-nil, just remove the keys from ALIST."
(dolist (bind alist)
(dolist (old (where-is-internal (car bind) windmove-mode-map))
(define-key windmove-mode-map old nil))
(unless uninstall
(let ((key (vconcat (if (or (equal prefix [ignore])
(eq prefix 'none))
nil prefix)
(list (append modifiers (cdr bind))))))
(when (eq (key-binding key) #'self-insert-command)
(warn "Command %S is shadowing self-insert-key" (car bind)))
(let ((old-fn (lookup-key windmove-mode-map key)))
(when (functionp old-fn)
(warn "Overriding %S with %S" old-fn (car bind))))
(define-key windmove-mode-map key (car bind))))))