eventPoint QML 类型
QEventPoint 的 Qml 等价物。更多...
导入语句 | import QtQuick |
实例化 | QEventPoint |
详细描述
eventPoint 是 QEventPoint 的 Qml 值类型表示。它具有与 QEventPoint 相同的属性。
以下属性可用:
- bool
eventPoint.accepted
:另请参阅 QEventPoint::accepted - PointerDevice
eventPoint.device
:另请参阅 QEventPoint::device - size
eventPoint.ellipseDiameters
:另请参阅 QEventPoint::ellipseDiameters - point
eventPoint.globalGrabPosition
:另请参阅 QEventPoint::globalGrabPosition - point
eventPoint.globalLastPosition
:另请参阅 QEventPoint::globalLastPosition - point
eventPoint.globalPosition
:另请参阅 QEventPoint::globalPosition - point
eventPoint.globalPressPosition
:另请参阅 QEventPoint::globalPressPosition - bool
eventPoint.grabPosition
:另请参阅 QEventPoint::grabPosition - int
eventPoint.id
:另请参阅 QEventPoint::id - point
eventPoint.lastPosition
:另请参阅 QEventPoint::lastPosition - ulong
eventPoint.lastTimestamp
:另请参阅 QEventPoint::lastTimestamp - point
eventPoint.position
:另请参阅 QEventPoint::position - point
eventPoint.pressPosition
:另请参阅 QEventPoint::pressPosition - int
eventPoint.pressTimestamp
:另请参阅 QEventPoint::pressTimestamp - real
eventPoint.pressure
:另请参阅 QEventPoint::pressure - real
eventPoint.rotation
:另请参阅 QEventPoint::rotation - point
eventPoint.sceneGrabPosition
:另请参阅 QEventPoint::sceneGrabPosition - point
eventPoint.sceneLastPosition
:另请参阅 QEventPoint::sceneLastPosition - point
eventPoint.scenePosition
:另请参阅 QEventPoint::scenePosition - ulong
eventPoint.pressTimestamp
:另请参阅 QEventPoint::pressTimestamp - point
eventPoint.scenePressPosition
:另请参阅 QEventPoint::scenePressPosition - enumeration
eventPoint.state
:另请参阅 QEventPoint::state - real
eventPoint.timeHeld
:另请参阅 QEventPoint::timeHeld - ulong
eventPoint.timestamp
:另请参阅 QEventPoint::timestamp - pointingDeviceUniqueId
eventPoint.uniqueId
:另请参阅 QEventPoint::uniqueId - vector2d
eventPoint.velocity
:另请参阅 QEventPoint::velocity
状态支持以下值
常量 | 描述 |
---|---|
EventPoint.Unknown | 未知状态;与Qt.TouchPointUnknownState相同 |
EventPoint.Stationary | 事件点没有移动;与Qt.TouchPointStationary相同 |
EventPoint.Pressed | 触摸点或按钮被按下;与Qt.TouchPointPressed相同 |
EventPoint.Updated | 事件点已更新;与Qt.TouchPointMoved相同 |
EventPoint.Released | 触摸点或按钮被释放;与Qt.TouchPointReleased相同 |
The States type 是 QFlags<State> 的 typedef。它存储了 State 值的按位或组合。另请参阅 QEventPoint::States
TapHandler { gesturePolicy: TapHandler.ReleaseWithinBounds // exclusive grab on press onGrabChanged: (transition, eventPoint) => { switch (transition) { case PointerDevice.GrabExclusive: console.log("took exclusive grab of point", eventPoint.id, "on", eventPoint.device.name) break case PointerDevice.UngrabExclusive: console.log("gave up exclusive grab of point", eventPoint.id, "on", eventPoint.device.name) break case PointerDevice.CancelGrabExclusive: console.log("exclusive grab of point", eventPoint.id, "on", eventPoint.device.name, "has been cancelled") break } switch (eventPoint.state) { case EventPoint.Pressed: console.log("on press @", eventPoint.position); break case EventPoint.Updated: console.log("on update @", eventPoint.position); break case EventPoint.Released: console.log("on release @", eventPoint.position); break default: console.log(eventPoint.position, "state", eventPoint.state) break } } }
另请参阅handlerPoint。
© 2024 Qt 公司。本文件中的文档贡献者是各自版权的所有者。本文件中的文档是根据由自由软件基金会发布的 GNU 自由文档许可版 1.3 的条款许可的。Qt 和相应的标志是芬兰的 Qt 公司和/或在其他国家和地区的商标。所有其他商标都是各自所有者的财产。