QKeyEventTransitionclass provides a transition for key events. 更多 …
4.6 版新增。
def
key
()
def
modifierMask
()
def
setKey
(key)
def
setModifierMask
(modifiers)
QKeyEventTransitionis part of 状态机框架 .另请参阅
addTransition()
QKeyEventTransition
(
object
,
type
,
key
[
,
sourceState=None
]
)
¶
QKeyEventTransition([sourceState=None])
- param type
Type- param sourceState
QState- param object
QObject- param key
int
Constructs a new key event transition for events of the given
type
为给定
object
,采用给定
key
and
sourceState
.
Constructs a new key event transition with the given
sourceState
.
PySide2.QtWidgets.QKeyEventTransition.
key
(
)
¶
int
Returns the key that this key event transition checks for.
另请参阅
PySide2.QtWidgets.QKeyEventTransition.
modifierMask
(
)
¶
KeyboardModifiers
Returns the keyboard modifier mask that this key event transition checks for.
另请参阅
PySide2.QtWidgets.QKeyEventTransition.
setKey
(
key
)
¶
key
–
int
设置
key
that this key event transition will check for.
另请参阅
PySide2.QtWidgets.QKeyEventTransition.
setModifierMask
(
modifiers
)
¶
modifiers
–
KeyboardModifiers
Sets the keyboard modifier mask that this key event transition will check for to
modifierMask
.
另请参阅