[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: How to capture keystrokes when GTK menu is open?
- From: "Brian J. Tarricone" <bjt23 cornell edu>
- Cc: GTK App Dev Mailing List <gtk-app-devel-list gnome org>
- Subject: Re: How to capture keystrokes when GTK menu is open?
- Date: Tue, 20 Feb 2007 10:30:08 -0800
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tue, 20 Feb 2007 22:34:38 +1100 Justin Clift wrote:
> Whenever any gtk program has it's menu open, keystrokes don't seem to
> be processed for anything other than what's in the menu itself. i.e.
> the up, down, and enter keys work (and maybe shortcuts), and that's
> it. (These keys move the selection up and down the menu that's open)
>
> There doesn't seem to be a way to gets other keys fed through to
> things expecting them.
Yes, when gtk pops up a menu, it does a keyboard grab to ensure that
the menu gets all key events.
> So, recommendations on what to do from here? Is there a way to tell
> GTK to feed keystrokes onwards when a menu is open?
I don't believe so, no, but someone else may have a better answer.
> All other suggestions welcome of course. :)
Well, you can do what the Gimp's screenshot app does: allow the user to
start the screenshot process, and then have it delay a couple seconds.
So the usage could be:
1. Tell the app to do a screenshot in 3 seconds. (Maybe
ctrl+PrintScreen could be "delayed capture".)
2. Pop up the menu.
3. Wait.
4. App takes screenshot.
-brian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
iD8DBQFF2z426XyW6VEeAnsRAj53AKCwo3o7SVpVlpDWWkr7ilb0EVIgBACcD3CO
bqKw+69FdxBHnuNaA5Yb1Hg=
=6I74
-----END PGP SIGNATURE-----
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]