describe-keymap: Suggest symbol at point
* lisp/help-fns.el (describe-keymap): Suggest symbol at point if it is a keymap. (Bug#55393) * etc/NEWS: Announce change in behavior of 'describe-keymap'.
This commit is contained in:
parent
b90909050d
commit
9ac40fb980
2 changed files with 9 additions and 1 deletions
5
etc/NEWS
5
etc/NEWS
|
@ -562,6 +562,11 @@ minor modes are listed after the major mode.
|
|||
The apropos commands will now select the apropos window if
|
||||
'help-window-select' is non-nil.
|
||||
|
||||
---
|
||||
*** 'describe-keymap' now considers the symbol at point.
|
||||
If the symbol at point is a keymap, 'describe-keymap' suggests it as
|
||||
the default candidate.
|
||||
|
||||
** Outline Mode
|
||||
|
||||
+++
|
||||
|
|
|
@ -1922,7 +1922,10 @@ in `describe-keymap'. See also `Searching the Active Keymaps'."
|
|||
When called interactively, prompt for a variable that has a
|
||||
keymap value."
|
||||
(interactive
|
||||
(let* ((km (help-fns--most-relevant-active-keymap))
|
||||
(let* ((sym (symbol-at-point))
|
||||
(km (or (and (keymapp (ignore-errors (symbol-value sym)))
|
||||
sym)
|
||||
(help-fns--most-relevant-active-keymap)))
|
||||
(val (completing-read
|
||||
(format-prompt "Keymap" km)
|
||||
obarray
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue