bug#6956: 24.0.50; pasting mouse selection in other session pastes only first word
Eli Zaretskii <eliz <at> gnu.org>
2010-09-01 14:38:31 GMT
> From: Chong Yidong <cyd <at> stupidchicken.com>
> Cc: Drew Adams <drew.adams <at> oracle.com>, 6956 <at> debbugs.gnu.org
> Date: Tue, 31 Aug 2010 14:13:30 -0400
> Eli Zaretskii <eliz <at> gnu.org> writes:
> >> Select some text (several words) with the mouse using double-click
> >> mouse-1 on one word then mouse-3 on a later word in the text.
> > Does this constitute a "mouse drag"? Can someone please tell what
> > happens on X with the recipe in this bug report?
> Yes, this follows the rule that if the region is highlighted, the
> primary selection is set. On X, if you double-mouse-1 on a word and
> extend the region with mouse-3, you can use mouse-2 to paste the entire
> selection into another application.
The issue here is that mouse-drag-copy-region is advertised to copy to
the kill-ring regions which are highlighted by dragging the mouse.
But mouse-drag-copy-region only affects mouse-drag-region (via
mouse-drag-track), which is bound to mouse-1. Mouse-3, OTOH, is bound
to mouse-save-then-kill, which is not affected at all by
So when Drew double-clicks mouse-1, the highlighted first word is
indeed copied into the kill ring (and winds up in the clipboard), but
extending the region with mouse-3 doesn't copy the extended region.
What I think happens on X under mouse-drag-copy-region is that the
first word is copied into the clipboard, while the extended region is