Re: terminals and urls and copying

[prev] [thread] [next] [lurker] [Date index for 2004/03/24]

From: Phil!Gregory
Subject: Re: terminals and urls and copying
Date: 18:48 on 24 Mar 2004
* Simon Wistow <simon@xxxxxxxxxx.xxx> [2004-03-24 18:08 +0000]:
> I go back. I look again. Oh, I see, it was in an IRC window and somebody 
> has said something so the line I highlighted has moved up. 
> 
> CLEARLY THIS MEANT THAT YOU SHOULD CLEAR THE CLIPBOARD. YOU PIECE OF 
> SHIT.

You, sir, have stolen my rant on a hate that has bothered me for quite a
while now.  So I'll just feed off your post.

Cut-and-paste in X is so very hateful.  For most apps, merely hilighting
text is sufficient to put that text into the "clipboard", thus clobbering
whatever was in there previously.  Having a keystroke combination to do
this taskand avoid accidental deletion of data would be too complicated
for the designers of these programs.  (And now the behaviour is standard,
so no one dares change it.)  But, like the fact that Unix filesystems have
no undelete, one eventually gets used to it and doesn't delete important
stuff more than every other month.

There is, of course, more.  I put "clipboard" in quotes up there.  X
doesn't really have a clipboard.  All of the above behaviour is done with
"selections".  Selections are owned by individual programs, not by the X
server.  So when you paste from one xterm to another, the second xterm
actually goes and asks the first one for its selection.  If the first one
has lost its data for some reason, it returns nothing.  And there's no
buffer in X to hold on to the text after the originating program forgets
about it.  (There is a selection named "Clipboard", but it workes the same
way as the "Primary" selection, which is what everyone uses.  The client
still owns the data.)

So, xterm is too dumb to keep highlighted text selected if it scrolls up
the screen (even though it *knows* that it's scrolling and it *knows*
exactly where the text you selected ended up) and X is too dumb to use a
real clipboard and manage the data itself, so your selected text has a
tendency to vanish.

*Hate*

More on selections can be found at

  http://www.jwz.org/doc/x-cut-and-paste.html

-- 
...computer contrarian of the first order... / http://aperiodic.net/phil/
PGP: 026A27F2  print: D200 5BDB FC4B B24A 9248  9F7A 4322 2D22 026A 27F2
--- --
The different branches of Arithmetic -- Ambition, Distraction,
Uglification, and Derision.
                       -- _Alice in Wonderland_, Lewis Carroll
---- --- --

Generated at 14:02 on 01 Jul 2004 by mariachi 0.52