Class: QgsAnnotationItemEditOperationMoveNode¶
Annotation item edit operation consisting of moving a node.
Added in version 3.22.
Class Hierarchy¶
Base classes¶
Abstract base class for annotation item edit operations. |
Methods
Returns the node position after the move occurred (in layer coordinates). |
|
Returns the node position before the move occurred (in layer coordinates). |
|
Returns the associated node ID. |
|
Returns the x-axis translation, in pixels. |
|
Returns the y-axis translation, in pixels. |
- class qgis.core.QgsAnnotationItemEditOperationMoveNode[source]¶
Bases:
QgsAbstractAnnotationItemEditOperation
- __init__(itemId: str | None, nodeId: QgsVertexId, before: QgsPoint, after: QgsPoint, translatePixelsX: float = 0, translatePixelsY: float = 0)
Constructor for QgsAnnotationItemEditOperationMoveNode, where the node with the specified
id
moves frombefore
toafter
(in layer coordinates).Since QGIS 3.40 the
translatePixelsX
andtranslatePixelsY
arguments specify the translation in pixels.- Parameters:
itemId (Optional[str])
nodeId (QgsVertexId)
before (QgsPoint)
after (QgsPoint)
translatePixelsX (float = 0)
translatePixelsY (float = 0)
- __init__(a0: QgsAnnotationItemEditOperationMoveNode)
- Parameters:
- after(self) QgsPoint [source]¶
Returns the node position after the move occurred (in layer coordinates).
See also
- Return type:
- before(self) QgsPoint [source]¶
Returns the node position before the move occurred (in layer coordinates).
See also
- Return type:
- nodeId(self) QgsVertexId [source]¶
Returns the associated node ID.
- Return type:
- translationXPixels(self) float [source]¶
Returns the x-axis translation, in pixels.
since
translationYPixels()
Added in version 3.40.
- Return type:
float
- translationYPixels(self) float [source]¶
Returns the y-axis translation, in pixels.
since
translationXPixels()
Added in version 3.40.
- Return type:
float