[Qt-interest] How to catch key press/release first?

R. Reucher rene.reucher at batcom-it.net
Fri May 15 13:07:41 CEST 2009


On Fri May 15 2009 12:58:42 Martin Gebert wrote:
> I'm currently exploring possibilities to catch key press and release events
> for the cursor keys and handle them before any other widget gets the
> chance.
You need to create an event filter and install it on the QApplication object.

See http://doc.qtsoftware.com/4.5/qobject.html#installEventFilter

HTH, René

PS: If you need a more complicated example, I can give you a link to a project 
of mine where I'm using this method.
-- 
René Reucher
rene.reucher at batcom-it.net
http://www.batcom-it.net/

The economy depends about as much on economists as the weather does on
weather forecasters.
		-- Jean-Paul Kauffmann




More information about the Qt-interest-old mailing list