I am working on a clipboard manager. My current issue is to succeed in catching modification of the clipboard from any applications. For instance :
The idea is that a python script is running in background, like a deamon and catch every change of the clipboard
Thank you a lot :)
PS: For people who know autohotkey, I am looking for onClipboardChange equivalent
I found in the web a solution using GTK:
from gi.repository import Gtk, Gdk
def callBack(*args):
print("Clipboard changed. New value = " + clip.wait_for_text())
clip = Gtk.Clipboard.get(Gdk.SELECTION_CLIPBOARD)
clip.connect('owner-change', callBack)
Gtk.main()