
QApplication::sendEvent(this, new QKeyEvent (QEvent::KeyPress, Qt::Key_Dead_Diaeresis, Qt::NoModifier, QString("ยจ"))); //Another way I guess easy to understand :) //Although both are same QKeyEvent keyEvent(QEvent::KeyPress,Qt::Key_Escape, Qt::NoModifier); QApplication::sendEvent(this, &keyEvent);
This blog has been loading slowly for me the final few days. I thought maybe it was my pc, but my sister visits your web site as well and she told me the identical factor is occurring to her. Any ideas?
what is `this` ? You are firing it from where ? is it targated to some widget ? or to currently focused Widget ? What if the currently focused Widget is not a Qt Widget
this object can be replaced with any other Qt Widget but not any external widget
Hi! Does this code actually make the keystroke affect other applications? For example, if I were to send a page down with my qt application using this code would it affect a powerpoint presentation being shown?