Skip to content Skip to sidebar Skip to footer

Detect Specific Keypresses In Gui

I'm looking for a way in Gtk/Python to have an app listen for keypresses and when some of the special keys are pressed, perform an action (recreate a menu with different labels, si

Solution 1:

You probably need to handle the "key-press-event" (and probably also "key-release-event") of GtkWidget. PyGtk knows about it.

It should be inside some "windowing" widget, so you may need to use GtkEventBox as a container.

Post a Comment for "Detect Specific Keypresses In Gui"