emacs-devel
[Top][All Lists]
Advanced

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

Re: visual-region-mode?


From: Charles A. Roelli
Subject: Re: visual-region-mode?
Date: Thu, 20 Sep 2018 20:14:51 +0200

> From: hw <address@hidden>
> Date: Wed, 19 Sep 2018 22:04:14 +0200
> 
> Simple instructions can be very inefficient, for example by leaving out
> important information, by oversimplifying things or by trying to dumb
> things down.

Yes, though it's rare to hear such accusations against Emacs.

> With t-m-m disabled, there is no way to fortify the region, and there is
> no highlighting.  Why would I disable it?

There would be a way to "fortify" the region, if you had another
binding for toggling whether the region is active or not.

> With t-m-m disabled, the region can not be activated, so why would I try
> to do that?  My function is ignorant of t-m-m anyway.
> 
> Why would I disable t-m-m only to ask to temporarily enable it?

That's how the current implementation is designed: the region is
considered "active" when both "mark-active" is non-nil /and/ "t-m-m"
is on.  Unfortunately, the doc on this is unclear -- at least,
"mark-active" needs to clarify that its value is only taken into
account with "t-m-m" on:

    mark-active is a variable defined in ‘buffer.c’.
    Non-nil means the mark and region are currently active in this buffer.

    region-active-p is a compiled Lisp function in ‘simple.el’.
    Return non-nil if Transient Mark mode is enabled and the mark is active.

I'd like to be able to "activate" the region with "t-m-m" off to use
commands that behave differently when the region is active (like M-%),
without the highlighting that "t-m-m" forces, and without the region
randomly deactivating itself after certain commands as it does with
"t-m-m" switched on.  Highlighting the region could be a separate
mode.

> Are there any disadvantages of having t-m-m enabled that would overcome
> all the advantages of having it disabled?

Not sure I understand this.



reply via email to

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