内容表

上一话题

QPanGesture

下一话题

QPlainTextDocumentLayout

QPinchGesture

QPinchGesture class describes a pinch gesture made by the user. 更多

Inheritance diagram of PySide2.QtWidgets.QPinchGesture

4.6 版新增。

详细描述

A pinch gesture is a form of touch user input in which the user typically touches two points on the input device with a thumb and finger, before moving them closer together or further apart to change the scale factor, zoom, or level of detail of the user interface.

For an overview of gesture handling in Qt and information on using gestures in your applications, see the 在 Widget 和图形视图中的手势 文档。

../../_images/pinchgesture.png

Instead of repeatedly applying the same pinching gesture, the user may continue to touch the input device in one place, and apply a second touch to a new point, continuing the gesture. When this occurs, gesture events will continue to be delivered to the target object, containing an instance of QPinchGesture GestureUpdated 状态。

class QPinchGesture ( [ parent=None ] )
参数

parent QObject

PySide2.QtWidgets.QPinchGesture. ChangeFlag

This enum describes the changes that can occur to the properties of the gesture object.

常量

描述

QPinchGesture.ScaleFactorChanged

The scale factor held by scaleFactor 改变。

QPinchGesture.RotationAngleChanged

The rotation angle held by rotationAngle 改变。

QPinchGesture.CenterPointChanged

The center point held by centerPoint 改变。

PySide2.QtWidgets.QPinchGesture. centerPoint ( )
返回类型

QPointF

另请参阅

setCenterPoint()

PySide2.QtWidgets.QPinchGesture. changeFlags ( )
返回类型

ChangeFlags

另请参阅

setChangeFlags()

PySide2.QtWidgets.QPinchGesture. lastCenterPoint ( )
返回类型

QPointF

PySide2.QtWidgets.QPinchGesture. lastRotationAngle ( )
返回类型

qreal

PySide2.QtWidgets.QPinchGesture. lastScaleFactor ( )
返回类型

qreal

PySide2.QtWidgets.QPinchGesture. rotationAngle ( )
返回类型

qreal

PySide2.QtWidgets.QPinchGesture. scaleFactor ( )
返回类型

qreal

另请参阅

setScaleFactor()

PySide2.QtWidgets.QPinchGesture. setCenterPoint ( value )
参数

value QPointF

另请参阅

centerPoint()

PySide2.QtWidgets.QPinchGesture. setChangeFlags ( value )
参数

value ChangeFlags

另请参阅

changeFlags()

PySide2.QtWidgets.QPinchGesture. setLastCenterPoint ( value )
参数

value QPointF

另请参阅

lastCenterPoint()

PySide2.QtWidgets.QPinchGesture. setLastRotationAngle ( value )
参数

value qreal

PySide2.QtWidgets.QPinchGesture. setLastScaleFactor ( value )
参数

value qreal

另请参阅

lastScaleFactor()

PySide2.QtWidgets.QPinchGesture. setRotationAngle ( value )
参数

value qreal

另请参阅

rotationAngle()

PySide2.QtWidgets.QPinchGesture. setScaleFactor ( value )
参数

value qreal

另请参阅

scaleFactor()

PySide2.QtWidgets.QPinchGesture. setStartCenterPoint ( value )
参数

value QPointF

PySide2.QtWidgets.QPinchGesture. setTotalChangeFlags ( value )
参数

value ChangeFlags

PySide2.QtWidgets.QPinchGesture. setTotalRotationAngle ( value )
参数

value qreal

PySide2.QtWidgets.QPinchGesture. setTotalScaleFactor ( value )
参数

value qreal

PySide2.QtWidgets.QPinchGesture. startCenterPoint ( )
返回类型

QPointF

PySide2.QtWidgets.QPinchGesture. totalChangeFlags ( )
返回类型

ChangeFlags

PySide2.QtWidgets.QPinchGesture. totalRotationAngle ( )
返回类型

qreal

PySide2.QtWidgets.QPinchGesture. totalScaleFactor ( )
返回类型

qreal