|
From: <tim...@en...> - 2006-02-03 19:05:28
|
Ethan Merritt wrote: >On Friday 03 February 2006 09:51 am, Timoth=C3=A9e Lecomte wrote: > =20 > >>The plot graph appears in klipper, but I can't paste it anyway but >>after selecting it in klipper. If I don't select it in klipper, or if >>klipper is not launched, I have nothing at all to paste ! I've tried >>with both kde apps (KolourPaint) and non-kde (Gimp). I'm not sure >>this is the expected behaviour ;-) >>That's probably because you "remove gnuplot_x11 from the selection >>list". As far as I understand, the app is intended to keep the >>ownership of the clipboard as long as it provides something in it. >> =20 >> > >That does not make much sense to me. >If the original source is still available for selection, then you can >copy-and-paste without going through klipper at all. > >Normally if I select something it continues to appear in the klipper >history even after the original app exits. That way you can paste >things selected earlier in your session, long after the original >place you selected it from is gone. Isn't that the whole point of >klipper? > =20 > Of klipper, yes, but not the point of the clipboard/selection in general. Klipper stores a copy of each content in the clipboard, so that it can be used even if the app is not running anymore, but if you don't have klipper launched, I'm pretty sure you lose everything, unless you use some tricks that may be implemented in toolkits. My point is that unless I use klipper I can't get the copied graph. It is the same with your patches or with my patch or without any of them. That may be why nobody seemed to know that the x11 terminal has this feature. However, there must be a way to make the graph available more directly, as gtk/wxwidgets/qt are able to do it... With my terminal (which has problems too with the clipboard by the way) if I copy the graph to the clipboard, I just have to click on "paste" and it effectively pastes, even without klipper. >>I tried myself, and got it working with the attached diff (against >>cvs before your patches). >> =20 >> > >You are doing better than I am :-) >So your diff is against the cvs version from before 1 Feb 2006? > =20 > Yes, it is. >I'll have a look. > >I worry a bit that in changing the code to work with KDE >we may lose compatibility with whatever environment it was >originally written for. Since I have never used this cut-and-paste >of whole plot image myself, I don't have any historical usage to >compare with. > =20 > Me too. I would say -apart from kde or whatever window manager- we should comply with ICCCM conventions, explained in the previous links. In particular : "TIMESTAMP - To avoid some race conditions, it is important that requestors be able to discover the timestamp the owner used to acquire ownership. Until and unless the protocol is changed so that a GetSelectionOwner request returns the timestamp used to acquire ownership, selection owners must support conversion to TIMESTAMP, returning the timestamp they used to obtain the selection." >>There's one (small) problem that I don't understand : the first graph >>(when it is first plotted) appears twice in klipper, and the >>pixmap/colormap cases are triggered twice for this first time. >> =20 >> >In following one trail of links from the klipper bug report you sent >earlier, I came across a separate bug report that klipper was >sometimes triggering selection events from its own selection buffer, >causing double entries. Perhaps this is an example. > =20 > Maybe ! In all cases, it's definitely better than the initial situation of an unlimited number of copies in klipper ! Best regards, Timoth=C3=A9e |