EventPoint QML Type
|Import Statement:||import QtQuick 2.12|
- accepted : bool
- pointId : int
- position : point
- sceneGrabPosition : point
- scenePosition : point
- scenePressPosition : point
- state : int
- timeHeld : real
- velocity : vector2d
Setting accepted to true prevents the event from being propagated to Items below the PointerHandler's Item.
Generally, if the handler acts on the mouse event, then it should be accepted so that items lower in the stacking order do not also respond to the same event.
This property holds the ID of the event, if any.
Touchpoints have automatically-incrementing IDs: each time the user presses a finger against the touchscreen, it will be a larger number. In other cases, it will be -1.
See also uniqueId.
This property holds the coordinates of the position supplied by the event, relative to the upper-left corner of the Item which has the PointerHandler. If a contact patch is available from the pointing device, this point represents its centroid.
This property holds the scene-relative position at which the EventPoint was located when setGrabber() was called most recently.
This property holds the coordinates of the position supplied by the event, relative to the scene. If a contact patch is available from the device, this point represents its centroid.
This property holds the scene-relative position at which the press event (on a touch device) or most recent change in QQuickPointerEvent::buttons() (on a mouse or tablet stylus) occurred.
This property tells what the user is currently doing at this point.
It can be one of:
|The user's finger is now pressing a touchscreen, button or stylus which was not pressed already|
|The touchpoint or position is being moved, with no change in pressed state|
|The touchpoint or position is not being moved, and there is also no change in pressed state|
|The user's finger has now released a touch point, button or stylus which was pressed|
This property holds the amount of time in seconds that the button or touchpoint has been held. It can be used to detect a "long press", and can drive an animation to show progress toward activation of the "long press" action.
[read-only] velocity : vector2d
This property holds average recent velocity: how fast and in which direction the event point has been moving recently.