Subject: Re: bug#902: select-active-regions only half-working

From: David De La Harpe Golden <[email-masked]>
Date: Sat, 06 Sep 2008 21:22:36 +0100

Stefan Monnier wrote:
>> The select-active-regions in-tree does not work in all cases - it works
>> when the region is changed by moving the mark but not when it is changed
>> by certain other means e.g. moving the point with the keyboard.
>> (Workaround:  C-x C-x C-x C-x ...).
> 
> Could you be more precise and give an actual recipe?
> 

With transient-mark-mode and select-active-regions on:

Set mark. (C-SPC)

Move point with keyboard, defining an active region.

Try to middle-click-paste into another application (that
accepts middle clicks to paste in primary, of course)

Note that what is pasted in doesn't correspond to the
active region. It should.

Sorry, this was a known issue pre-bug-tracker, should really have
been filed a long time ago:
http://lists.gnu.org/archive/html/emacs-devel/2008-02/msg00327.html
(includes very similar patches that no longer apply cleanly)

There might still be a related ordering issue in mouse-drag-track too,
that caused annoying off-by-a-little-bit glitches when mouse-selecting:

http://lists.gnu.org/archive/html/emacs-devel/2008-02/msg00316.html