emacs-devel
[Top][All Lists]
Advanced

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

Re: Context menus and mouse-3


From: Juri Linkov
Subject: Re: Context menus and mouse-3
Date: Fri, 16 Jul 2021 21:59:39 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu)

>> >> And some modes like org-mode, flyspell-mode, etc. already redefine
>> >> down-mouse-3 to pop up context menus.
>> >
>> > But those modes define those context menus on special parts of
>> > display, where pasting etc. makes less sense, no?
>> 
>> When the buffer is not read-only, I see no reason to disallow
>> pasting text because e.g. in flyspell-mode it makes sense
>> to paste a correction to a misspelled word, etc.
>
> IMO, when mouse-3 is clocked on a misspelled word, it makes much more
> sense to assume the user wants to fix that word than that the user
> wants to paste.
>
> But here's an idea: how about merging the two menus into one in these
> cases?  We could add a top-level menu with the two alternatives, each
> one would then drop down one of the two possible menus.
> Alternatively, just make a long menu by concatenating the contents of
> the two original ones.
>
> WDYT?

Tak Kunihiro had a very good idea of using a hook-like variable
that contains a list of functions that return parts of the whole
context-menu, then these parts will be collected into the final menu.



reply via email to

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