18#ifndef QGSANNOTATIONPOINTTEXTITEM_H
19#define QGSANNOTATIONPOINTTEXTITEM_H
44 QString
type()
const override;
84 QString
text()
const {
return mText; }
112 double angle()
const {
return mAngle; }
126 Qt::Alignment alignment()
const;
133 void setAlignment( Qt::Alignment alignment );
157 Qt::Alignment mAlignment = Qt::AlignHCenter;
Provides global constants and enumerations for use throughout the application.
SymbolRotationMode
Modes for handling how symbol and text entity rotation is handled when maps are rotated.
@ IgnoreMapRotation
Entity ignores map rotation.
QFlags< AnnotationItemFlag > AnnotationItemFlags
Annotation item flags.
Abstract base class for annotation item edit operations.
Encapsulates the context for an annotation item edit operation.
Encapsulates the transient results of an in-progress annotation edit operation.
Contains information about a node used for editing an annotation item.
virtual bool writeXml(QDomElement &element, QDomDocument &document, const QgsReadWriteContext &context) const =0
Writes the item's state into an XML element.
virtual QString type() const =0
Returns a unique (untranslated) string identifying the type of item.
virtual void render(QgsRenderContext &context, QgsFeedback *feedback)=0
Renders the item to the specified render context.
virtual Qgis::AnnotationItemFlags flags() const
Returns item flags.
An annotation item which renders a text string at a point location.
QgsPointXY point() const
Returns the point location of the text.
void setText(const QString &text)
Sets the text rendered by the item.
~QgsAnnotationPointTextItem() override
QgsAnnotationPointTextItem * clone() const override
Returns a clone of the item.
double angle() const
Returns the text's rotation angle, in degrees clockwise.
void setAngle(double angle)
Sets the text's rotation angle, in degrees clockwise.
QgsRectangle boundingBox() const override
Returns the bounding box of the item's geographic location, in the parent layer's coordinate referenc...
void setPoint(QgsPointXY point)
Sets the point location of the text.
static QgsAnnotationPointTextItem * create()
Creates a new text at point annotation item.
bool readXml(const QDomElement &element, const QgsReadWriteContext &context) override
Reads the item's state from the given DOM element.
QString text() const
Returns the text rendered by the item.
QgsAnnotationPointTextItem(const QString &text, QgsPointXY point)
Constructor for QgsAnnotationPointTextItem, containing the specified text at the specified point.
QList< QgsAnnotationItemNode > nodesV2(const QgsAnnotationItemEditContext &context) const override
Returns the nodes for the item, used for editing the item.
QgsAnnotationItemEditOperationTransientResults * transientEditResultsV2(QgsAbstractAnnotationItemEditOperation *operation, const QgsAnnotationItemEditContext &context) override
Retrieves the results of a transient (in progress) edit operation on the item.
Qgis::AnnotationItemEditOperationResult applyEditV2(QgsAbstractAnnotationItemEditOperation *operation, const QgsAnnotationItemEditContext &context) override
Applies an edit operation to the item.
Base class for feedback objects to be used for cancellation of something running in a worker thread.
A container for the context for various read/write operations on objects.
A rectangle specified with double values.
Contains information about the context of a rendering operation.
Container for all settings relating to text rendering.