Discussion:
r37097 - lyx-devel/trunk/src
(too old to reply)
Jean-Marc Lasgouttes
2011-01-04 08:23:18 UTC
Permalink
Author: sanda
Date: Tue Jan 4 02:41:53 2011
New Revision: 37097
URL: http://www.lyx.org/trac/changeset/37097
Update doxy for selection-paste.
The whole thing was introduced in r28154.
JMarc, could you improve the description doxies for selection-paste and primary-selection-paste ?
I do not know much besides what is written there. I presume that
the change I did at the time was just mechanical.

JMarc
Jean-Marc Lasgouttes
2011-01-04 11:12:30 UTC
Permalink
Post by Jean-Marc Lasgouttes
JMarc, could you improve the description doxies for selection-paste and primary-selection-paste ?
I do not know much besides what is written there. I presume that
the change I did at the time was just mechanical.
to me its not clear what is meant by 'permanent selection'...
Same for me. Enrico, do you know about that?

JMarc
Enrico Forestieri
2011-01-05 01:48:26 UTC
Permalink
Post by Jean-Marc Lasgouttes
Post by Jean-Marc Lasgouttes
JMarc, could you improve the description doxies for selection-paste and primary-selection-paste ?
I do not know much besides what is written there. I presume that
the change I did at the time was just mechanical.
to me its not clear what is meant by 'permanent selection'...
Same for me. Enrico, do you know about that?
Select something in LyX and then left-click away. Now the selection
disappears but you can still middle-paste the previosly selected text.
That's the permanent selection thingie: until you select something else,
the old selection is still available.

However, the way LyX interacts with other applications through the
selection is somewhat fishy. For example, try the following.
1) Select something in LyX and then left-click away. Selection disappears,
but you can still middle-paste the old selection within LyX. If you now
try middle-pasting to an external application (a terminal, for example)
nothing gets pasted.
2) Select something in LyX and then middle-paste into an external application.
Now left-click away in LyX. Selections disappears, but you can still
middle-paste the old selection both within LyX and into the external
application!

So, it seems that pasting the selection into an external application before
left-clicking away, makes the selection itself permanent also outside LyX.

Performing the same experiment with Vim, the selection is really permanent
also for external applications in both cases 1) and 2) above.
--
Enrico
Pavel Sanda
2011-01-05 17:04:53 UTC
Permalink
Post by Enrico Forestieri
Select something in LyX and then left-click away. Now the selection
disappears but you can still middle-paste the previosly selected text.
That's the permanent selection thingie: until you select something else,
the old selection is still available.
i see what you mean.
Post by Enrico Forestieri
However, the way LyX interacts with other applications through the
selection is somewhat fishy. For example, try the following.
1) Select something in LyX and then left-click away. Selection disappears,
but you can still middle-paste the old selection within LyX. If you now
try middle-pasting to an external application (a terminal, for example)
nothing gets pasted.
2) Select something in LyX and then middle-paste into an external application.
Now left-click away in LyX. Selections disappears, but you can still
middle-paste the old selection both within LyX and into the external
application!
So, it seems that pasting the selection into an external application before
left-clicking away, makes the selection itself permanent also outside LyX.
from what i remember this code was very touchy and even more weird things happened
when you run more lyx instances while trying different scenarious of middle button pasting.
because of performance issues we put selected text into 'real' permanent selection
only when you click-away and for this the internal logic became complicated.

for a long time i bear the idea to rewrite this stuff in a way that the selection is done
on mouse-release event instead.

pavel

Pavel Sanda
2011-01-04 09:53:01 UTC
Permalink
Post by Jean-Marc Lasgouttes
JMarc, could you improve the description doxies for selection-paste and primary-selection-paste ?
I do not know much besides what is written there. I presume that
the change I did at the time was just mechanical.
to me its not clear what is meant by 'permanent selection'...
pavel
Loading...