help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Making new menu after Tools using keymap-set-after


From: uzibalqa
Subject: Re: Making new menu after Tools using keymap-set-after
Date: Wed, 19 Jul 2023 15:58:10 +0000





Sent with Proton Mail secure email.

------- Original Message -------
On Wednesday, July 19th, 2023 at 9:10 PM, Robert Pluim <rpluim@gmail.com> wrote:


> > > > > > On Wed, 19 Jul 2023 08:08:32 +0000, uzibalqa uzibalqa@proton.me 
> > > > > > said:
> 
> 
> uzibalqa> (defvar mcp-kdf (make-sparse-keymap "MCP"))
> 
> uzibalqa> (keymap-set-after global-map
> 
> uzibalqa> "<menu-bar> <mcp-topm>" (cons "MCP" mcp-kdf) 'tools)
> 
> 
> uzibalqa> complains about 'tools
> 
> 
> Works for me in emacs-30, it gives me an 'MCP' menu just after
> Tools. What error are you seeing?
> 
> 
> Robert
> --

With GNU Emacs 29.0.50, I get 

Debugger entered--Lisp error: (error "tools is not a valid key definition; see 
‘key-valid-p’")
  signal(error ("tools is not a valid key definition; see ‘key-valid-p’"))
  error("%S is not a valid key definition; see `key-valid-p'" tools)
  keymap--check(tools)
  keymap-set-after((keymap #^[nil nil keymap 
#^^[3 0 set-mark-command move-beginning-of-line backward-char 
mode-specific-command-prefix delete-char move-end-of-line forward-char 
keyboard-quit help-command indent-for-tab-command 
electric-newline-and-maybe-indent kill-line recenter-top-bottom newline 
next-line open-line previous-line quoted-insert isearch-backward 
isearch-forward transpose-chars universal-argument scroll-up-command 
kill-region Control-X-prefix yank suspend-frame ESC-prefix toggle-input-method 
abort-recursive-edit nil undo self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command ...] #^^[1 0 #^^[2 
0 
#^^[3 0 set-mark-command move-beginning-of-line backward-char 
mode-specific-command-prefix delete-char move-end-of-line forward-char 
keyboard-quit help-command indent-for-tab-command 
electric-newline-and-maybe-indent kill-line recenter-top-bottom newline 
next-line open-line previous-line quoted-insert isearch-backward 
isearch-forward transpose-chars universal-argument scroll-up-command 
kill-region Control-X-prefix yank suspend-frame ESC-prefix toggle-input-method 
abort-recursive-edit nil undo self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command ...] 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command] 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command] 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command self-insert-command self-insert-command self-insert-command 
self-insert-command ...] (67108908 . text-scale-decrease) (67108910 . 
text-scale-increase) (f5 . modus-themes-toggle) (paste . clipboard-yank) (copy 
. clipboard-kill-ring-save) (cut . clipboard-kill-region) (f18 . 
clipboard-yank) (f16 . clipboard-kill-ring-save) (f20 . clipboard-kill-region) 
(C-wheel-down . mouse-wheel-text-scale) (C-wheel-up . mouse-wheel-text-scale) 
(C-mouse-5 . mouse-wheel-text-scale) (C-mouse-4 . mouse-wheel-text-scale) 
(C-M-wheel-down . mouse-wheel-global-text-scale) (C-M-wheel-up . 
mouse-wheel-global-text-scale) (C-M-mouse-5 . mouse-wheel-global-text-scale) 
(C-M-mouse-4 . mouse-wheel-global-text-scale) (M-wheel-right . mwheel-scroll) 
(M-wheel-left . mwheel-scroll) (M-wheel-down . mwheel-scroll) (M-wheel-up . 
mwheel-scroll) (M-mouse-7 . mwheel-scroll) (M-mouse-6 . mwheel-scroll) 
(M-mouse-5 . mwheel-scroll) (M-mouse-4 . mwheel-scroll) (S-wheel-right . 
mwheel-scroll) (S-wheel-left . mwheel-scroll) (S-wheel-down . mwheel-scroll) 
(S-wheel-up . mwheel-scroll) (S-mouse-7 . mwheel-scroll) (S-mouse-6 . 
mwheel-scroll) (S-mouse-5 . mwheel-scroll) (S-mouse-4 . mwheel-scroll) 
(wheel-right . mwheel-scroll) (wheel-left . mwheel-scroll) (wheel-down . 
mwheel-scroll) ...) "<menu-bar> <mcp-topm>" ("MCP" keymap "MCP") tools)
  mcp-menubar()




reply via email to

[Prev in Thread] Current Thread [Next in Thread]