Re: GUI-less app to capture key_press_events only



* Eric Lenio <eric lenio net> [2004-10-05 16:52]:
I have an unusual situation where I want my app to merely
capture key_press_events, without having any kind of GUI.
Is it possible to do this with Gtk2?

There are programs that capture keys globally, so it is possible
in X11 at least; whether Gtk2 provides a means to do it, I don't
know though.

If you're wondering why I don't just read from standard input,
it is because I want to capture when the control key is
pressed.  That is, the control key is pressed by itself.  I
also want to do the same for the shift key and mod key.

That sounds like what you want is curses. There is a wrapper
module for that on CPAN.

Regards,
-- 
Aristotle
"If you can't laugh at yourself, you don't take life seriously enough."



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]