Re: Cut/Copy/Paste Menu Selections

Damian Ivereigh <damian cisco com> writes: 
> However I would like to also change the "sensitivity" of the menu items
> according to various situations. The most obvious example is only making
> "paste" sensitive when there is actually something in the clipboard.
> I have searched around for some way to easily detect if there is
> something in the clipboard. However I have found no function or easy way
> to do this. Does anyone have any suggestions? Should I just give up?

I remember being this impossible but I don't remember all the
issues. Owen will know.

You can use XGetSelectionOwner() to see if someone owns the selection
(i.e. there's something to paste), but I don't think there's a good
way to know whether the available stuff to paste is something you know
how to paste. i.e. you can't find out the data types of the stuff on
the clipboard (text, image, postscript, Word document) without
actually trying to paste. I could be wrong.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]