Function: gnus-article-describe-bindings
gnus-article-describe-bindings is an interactive and byte-compiled
function defined in gnus-art.el.gz.
Signature
(gnus-article-describe-bindings &optional PREFIX)
Documentation
Show a list of all defined keys, and their definitions.
The optional argument PREFIX, if non-nil, should be a key sequence; then we display only bindings that start with that prefix.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/gnus/gnus-art.el.gz
(defun gnus-article-describe-bindings (&optional prefix)
"Show a list of all defined keys, and their definitions.
The optional argument PREFIX, if non-nil, should be a key sequence;
then we display only bindings that start with that prefix."
(interactive nil gnus-article-mode)
(gnus-article-check-buffer)
(let ((keymap (copy-keymap gnus-article-mode-map))
(map (copy-keymap gnus-article-send-map))
(sumkeys (where-is-internal 'gnus-article-read-summary-keys))
(summap (make-sparse-keymap))
parent agent draft)
(define-key keymap "S" map)
(define-key map [t] nil)
(define-key summap [t] #'undefined)
(with-current-buffer gnus-article-current-summary
(dolist (key sumkeys)
(define-key summap key (key-binding key (current-local-map))))
(set-keymap-parent
keymap
(if (setq parent (keymap-parent gnus-article-mode-map))
(prog1
(setq parent (copy-keymap parent))
(set-keymap-parent parent summap))
summap))
(set-keymap-parent map (key-binding "S"))
(let (key def gnus-pick-mode)
(while sumkeys
(setq key (pop sumkeys))
(cond ((and (vectorp key) (= (length key) 1)
(consp (setq def (aref key 0)))
(numberp (car def)) (numberp (cdr def)))
(when (< (max (car def) (cdr def)) 128)
(setq sumkeys
(append (mapcar
#'vector
(nreverse (range-uncompress def)))
sumkeys))))
((setq def (key-binding key))
(unless (eq def 'undefined)
(define-key keymap key def))))))
(when (boundp 'gnus-agent-summary-mode)
(setq agent gnus-agent-summary-mode))
(when (boundp 'gnus-draft-mode)
(setq draft gnus-draft-mode)))
(with-temp-buffer
(use-local-map keymap)
(setq-local gnus-agent-summary-mode agent)
(setq-local gnus-draft-mode draft)
(describe-bindings prefix))
(let* ((cb (current-buffer))
(item `(,(lambda (prefix)
(with-current-buffer cb
(gnus-article-describe-bindings prefix)))
,prefix)))
;; Loading `help-mode' here is necessary if `describe-bindings'
;; is replaced with something, e.g. `helm-descbinds'.
(require 'help-mode)
(with-current-buffer (let (help-xref-following) (help-buffer))
(setq help-xref-stack-item item)))))