The QShortcutEvent class provides an event which is generated when the user presses a key combination. 更多...
头: | #include <QShortcutEvent> |
qmake: | QT += gui |
继承: | QEvent |
QShortcutEvent (const QKeySequence & key , int id , bool ambiguous = false) | |
~QShortcutEvent () | |
bool | isAmbiguous () const |
const QKeySequence & | key () const |
int | shortcutId () const |
The QShortcutEvent class provides an event which is generated when the user presses a key combination.
通常,不需要直接使用此类; QShortcut 提供处理快捷键的更高级别接口。
另请参阅 QShortcut .
构造快捷键事件为给定 key 按下,关联 QShortcut ID id .
ambiguous specifies whether there is more than one QShortcut for the same key sequence.
销毁事件对象。
返回
true
if the key sequence that triggered the event is ambiguous.
另请参阅 QShortcut::activatedAmbiguously ().
Returns the key sequence that triggered the event.
Returns the ID of the QShortcut object for which this event was generated.
另请参阅 QShortcut::id ().