On 2025-03-30, Travis Shelton wrote:

> This occurs within less than a second, before I can act on the clipboard.
> 
> Using `xwininfo', each of the `requestors' is related to `Qt Clipboard 
> Requestor Window'. Qt is probably part of my Desktop Environment.
> 
> I would like the above code to keep the ownership of `CLIPBOARD' for 
> example until I "fill" the clipboard manually from any other program. Is
> there some modification that can be done to accomplish this?

I do not have KDE around to confirm it, but that is probably because of
KDE's clipboard manager.  A clipboard manager can “steal” the CLIPBOARD
selection from other clients, especially if they do not support the
SAVE_TARGETS mechanism for clipboard managers.

You can try to terminate/kill KDE's clipboard manager while you are doing
your experiments with the CLIPBOARD selection.  Or you can edit the code
to use the PRIMARY selection instead, which clipboard managers (usually)
do not mess with.

-- 
Lucas de Sena.

Reply via email to