emacs-devel
[Top][All Lists]
Advanced

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

Re: [External] : Re: command mode-specificity [was: scratch/command 064f


From: Yuan Fu
Subject: Re: [External] : Re: command mode-specificity [was: scratch/command 064f146 1/2: Change...]
Date: Wed, 17 Feb 2021 14:02:15 -0500


> On Feb 17, 2021, at 6:20 AM, Lars Ingebrigtsen <larsi@gnus.org> wrote:
> 
> Stefan Monnier <monnier@iro.umontreal.ca> writes:
> 
>> Tho things can get murky: e.g. when dealing with multi-language buffers,
>> or with commands like `diff-refine-hunk` (which I often use in Gnus's
>> article buffers).
> 
> That's not a mode-specific command, so tagging it as such would be an
> error...
> 
> Multi-language buffers are an interesting problem, though.  But...  they
> work by switching `major-mode' around, don't they?  In which case,
> things should pretty much work automatically.  (I'm thinking of
> mhtml-mode.)
> 
>> IOW when you have one "language's" text in a buffer that's not using the
>> corresponding major mode.
> 
> I'm trying to think of cases where this would be a problem, but I'm
> having problems coming up with an example.

Org-time-stamp comes to my mind. Presumably it is intended to work in Org Mode 
only, but I use it in other places to insert a timestamp. Is there a way to 
easily override the scope setting for a command? And if a new user tries to use 
org-time-stamp and couldn’t find it in M-x, how could he know the problem is 
because of this scope setting?

Yuan


reply via email to

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