QGIS API Documentation 3.41.0-Master (af5edcb665c)
Loading...
Searching...
No Matches
Public Member Functions | List of all members
QgsAnnotationItemEditOperationMoveNode Class Reference

Annotation item edit operation consisting of moving a node. More...

#include <qgsannotationitemeditoperation.h>

Inheritance diagram for QgsAnnotationItemEditOperationMoveNode:
Inheritance graph
[legend]

Public Member Functions

 QgsAnnotationItemEditOperationMoveNode (const QString &itemId, QgsVertexId nodeId, const QgsPoint &before, const QgsPoint &after, double translatePixelsX=0, double translatePixelsY=0)
 Constructor for QgsAnnotationItemEditOperationMoveNode, where the node with the specified id moves from before to after (in layer coordinates).
 
QgsPoint after () const
 Returns the node position after the move occurred (in layer coordinates).
 
QgsPoint before () const
 Returns the node position before the move occurred (in layer coordinates).
 
QgsVertexId nodeId () const
 Returns the associated node ID.
 
double translationXPixels () const
 Returns the x-axis translation, in pixels.
 
double translationYPixels () const
 Returns the y-axis translation, in pixels.
 
Type type () const override
 Returns the operation type.
 
- Public Member Functions inherited from QgsAbstractAnnotationItemEditOperation
 QgsAbstractAnnotationItemEditOperation (const QString &itemId)
 Constructor for QgsAbstractAnnotationItemEditOperation, for the specified item id.
 
virtual ~QgsAbstractAnnotationItemEditOperation ()
 
QString itemId () const
 Returns the associated item ID.
 

Additional Inherited Members

- Public Types inherited from QgsAbstractAnnotationItemEditOperation
enum class  Type : int { MoveNode , DeleteNode , AddNode , TranslateItem }
 Operation type. More...
 
- Protected Attributes inherited from QgsAbstractAnnotationItemEditOperation
QString mItemId
 

Detailed Description

Annotation item edit operation consisting of moving a node.

Since
QGIS 3.22

Definition at line 122 of file qgsannotationitemeditoperation.h.

Constructor & Destructor Documentation

◆ QgsAnnotationItemEditOperationMoveNode()

QgsAnnotationItemEditOperationMoveNode::QgsAnnotationItemEditOperationMoveNode ( const QString &  itemId,
QgsVertexId  nodeId,
const QgsPoint before,
const QgsPoint after,
double  translatePixelsX = 0,
double  translatePixelsY = 0 
)

Constructor for QgsAnnotationItemEditOperationMoveNode, where the node with the specified id moves from before to after (in layer coordinates).

Since QGIS 3.40 the translatePixelsX and translatePixelsY arguments specify the translation in pixels.

Definition at line 59 of file qgsannotationitemeditoperation.cpp.

Member Function Documentation

◆ after()

QgsPoint QgsAnnotationItemEditOperationMoveNode::after ( ) const
inline

Returns the node position after the move occurred (in layer coordinates).

See also
before()

Definition at line 154 of file qgsannotationitemeditoperation.h.

◆ before()

QgsPoint QgsAnnotationItemEditOperationMoveNode::before ( ) const
inline

Returns the node position before the move occurred (in layer coordinates).

See also
after()

Definition at line 147 of file qgsannotationitemeditoperation.h.

◆ nodeId()

QgsVertexId QgsAnnotationItemEditOperationMoveNode::nodeId ( ) const
inline

Returns the associated node ID.

Definition at line 140 of file qgsannotationitemeditoperation.h.

◆ translationXPixels()

double QgsAnnotationItemEditOperationMoveNode::translationXPixels ( ) const
inline

Returns the x-axis translation, in pixels.

Since
translationYPixels()
QGIS 3.40

Definition at line 162 of file qgsannotationitemeditoperation.h.

◆ translationYPixels()

double QgsAnnotationItemEditOperationMoveNode::translationYPixels ( ) const
inline

Returns the y-axis translation, in pixels.

Since
translationXPixels()
QGIS 3.40

Definition at line 170 of file qgsannotationitemeditoperation.h.

◆ type()

QgsAbstractAnnotationItemEditOperation::Type QgsAnnotationItemEditOperationMoveNode::type ( ) const
overridevirtual

Returns the operation type.

Implements QgsAbstractAnnotationItemEditOperation.

Definition at line 71 of file qgsannotationitemeditoperation.cpp.


The documentation for this class was generated from the following files: