[Qt-interest] Virtual Keyboard

Girish Ramakrishnan girish at forwardbias.in
Fri Nov 26 17:52:39 CET 2010


Hi,

On Fri, Nov 26, 2010 at 3:24 PM, Paolo Quadrani <p.quadrani at cineca.it> wrote:
> Hi all,
> I'm trying to simulate the kayboard press event to allow my server
> application to generate keyboard event (like the press of F1 or a
> combination of keys like Ctrl+Z) to send to the active application like if
> the key press event was coming from the real keyboard.
> In Qt documentation I found everything related to event send/post QKeyEvent
> to a given QWidget but I can not find anything related to post event on OS
> like I can do using Cocoa (on Mac for example) by using native call:
> CGEventPost(kCGSessionEventTap, self.keyCommandDown);
> I need to be cross platform, so the reason of using Qt and not directly the
> Cocoa call.

Qt does not have a mechanism for this. You have to write platform specific code.

Girish



More information about the Qt-interest-old mailing list