[pygtk] XGrabKey?

Christian Reis kiko@async.com.br
Tue, 1 Oct 2002 17:29:22 -0300


On Mon, Sep 30, 2002 at 09:57:24AM -0400, Russell Nelson wrote:
> Urgh.  Thanks for the replies, but I don't want to grab the whole
> keyboard; just one key.  See, the problem is that another application
> has grabbed the key (for the same purpose as mine) but I want to
> override their grab (which as the window with the active focus I can).
> Once my pygps program exits my grab goes away, and the user sees the
> regular events.

If you can't find a way to do this using XGrabKeyboard, and I don't find
anything that wraps XGrabKey in Python for you (update: I can't), you
may have to write a custom wrapper. The problem is it seems GTK+-1.2
doesn't wrap it for you. 

Don't know if 2.0 does, though.

Take care,
--
Christian Reis, Senior Engineer, Async Open Source, Brazil.
http://async.com.br/~kiko/ | [+55 16] 261 2331 | NMFL