emacs-devel
[Top][All Lists]
Advanced

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

RE: poplife-mode


From: Drew Adams
Subject: RE: poplife-mode
Date: Mon, 13 Nov 2017 13:56:07 -0800 (PST)

> > AFAICT, it's the only way, with your approach, to see
> > the region you will act on get highlighted.  Are you
> > relegating your approach to menus that don't have items
> > that act on the region?
> 
> My suggestion is for a context menu.  I.e. a menu of things to apply
> locally.  Nothing specifically to do with the region.  The region is but
> one particular kind of "local" thing (and the down-mouse-3 event is not
> necessarily placed near the region).  I don't expect that the region
> would/will be the main use of this functionality.

I don't think acting on the region should be the _only_
use of a mouse-3 contextual menu, by any means.  That's
why mouse3.el, by default, gives you a non-region-oriented
menu if the region is not active and non-empty.  And you
can use any menus whatsoever - the menu to use in any
given context need not have anything to do with the region.

If option `mouse3-popup-include-global-menus-flag'
is non-nil, which it is by default, the mouse-3 menu
starts with the major-mode menu (or the `Menu Bar' menus
if the menu-bar is not visible).  And that comes first
in the mouse-3 menu.  So clearly there is nothing that
requires the menus to be related to the region.

But the general use of mouse-3 in Emacs is to act on the
region (extend, restrict, cut).  It makes sense, I think,
to at least provide for acting on the active region, and
be able to see it highlighted before doing so.

With mouse3.el, the menu that pops up when the region is
active is titled `Region', to point out that the current
context is one where the region is active.  Menu items
that make sense when the region is active are in general
natural candidates for that context.

When the region is empty or inactive, the menu title
is `No Region'.  But it is trivial to make these menu
titles customizable or to have only one mouse-3 menu
in any given context, regardless of whether the region
is active.



reply via email to

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