I'm trying to capture mouse clicks on an empty window using pygtk2.
Now, the code to do this is straight forward, and indeed, the exact same
procedures work in C (as can be evidenced by the fact that rox-tasklist
has menus)
Here's the code that doesn't work:
import pygtk
pygtk.require("2.0")
import gtk
def f(widget, event):
print "click"
w=gtk.Window()
w.set_decorated(0)
w.connect("destroy", gtk.mainquit)
w.connect("button_press_event", f)
w.show_all()
gtk.mainloop()
Can you not detect mouse clicks in pygtk for some reason?
_______________________________________________
pygtk mailing list [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
- Re: [pygtk] button-press-event in pygtk2 Robert Lowe
- Re: [pygtk] button-press-event in pygtk2 David M. Cook
