emacs-devel
[Top][All Lists]
Advanced

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

Re: Smarter M-x that filters on major-mode


From: Lars Ingebrigtsen
Subject: Re: Smarter M-x that filters on major-mode
Date: Thu, 11 Feb 2021 09:58:32 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> Similarly, you may mark some commands so they're just never available to
> `M-x`.  This could apply to some major and minor modes which are only
> meant to be used "internally", or to commands which only work when
> provided with a mouse event, or ...

Yup -- and from menus.  We have some commands that don't make sense
outside of a menu context, and have had bug reports about them because
people have discovered them via `M-x TAB' and then complained when they
don't work.

What would the syntax for marking these commands be?  Perhaps a
`declare' form would be the best thing here?  These commands are a lot
rarer than normal mode-specific commands (by several orders of
magnitude, I think), so if we go with

  (command foo-mode "p")

for the normal case, then perhaps it doesn't make sense to clutter up
that simple syntax with something for this thing.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no



reply via email to

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