1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-23 22:20:24 -08:00

Show the keybinding next to command in calc's x

* lisp/calc/calc-ext.el (calc-execute-extended-command): Use
M-x's ':affixation-function' to show the keybinding of the calc
command next to its name.  (Bug#74829)
This commit is contained in:
Visuwesh 2024-12-12 18:58:37 +05:30 committed by Eli Zaretskii
parent b561f896b5
commit aaacd5806c

View file

@ -1728,8 +1728,11 @@ calc-kill calc-kill-region calc-yank))))
(interactive "P")
(let* ((prompt (concat (calc-num-prefix-name n) "M-x "))
(cmd (intern
(completing-read prompt obarray 'commandp t "calc-"
'calc-extended-command-history))))
(let ((completion-extra-properties
(list :affixation-function
#'read-extended-command--affixation)))
(completing-read prompt obarray 'commandp t "calc-"
'calc-extended-command-history)))))
(setq prefix-arg n)
(command-execute cmd)))