15 #ifndef QGSTEXTLABELFEATURE_H 16 #define QGSTEXTLABELFEATURE_H 43 QString
text(
int partId )
const;
46 void calculateInfo(
bool curvedLabeling, QFontMetricsF *fm,
const QgsMapToPixel *xform,
double maxinangle,
double maxoutangle );
73 #endif //QGSTEXTLABELFEATURE_H QMap< QgsPalLayerSettings::Property, QVariant > mDataDefinedValues
Stores attribute values for data defined properties.
const QMap< QgsPalLayerSettings::Property, QVariant > & dataDefinedValues() const
Gets data-defined values.
QFontMetricsF * mFontMetrics
Metrics of the font for rendering.
QgsTextLabelFeature(QgsFeatureId id, GEOSGeometry *geometry, const QSizeF &size)
Construct text label feature.
QStringList mClusters
List of graphemes (used for curved labels)
~QgsTextLabelFeature()
Clean up.
Class that adds extra information to QgsLabelFeature for text labels.
void setDefinedFont(const QFont &f)
Sets font to be used for rendering.
GEOSGeometry * geometry() const
Gets access to the associated geometry.
QSizeF size() const
Size of the label (in map units)
Perform transforms between map coordinates and device coordinates.
QMap< QgsPalLayerSettings::DataDefinedProperties, QVariant > mDataDefinedValues
Stores attribute values for data defined properties.
std::unique_ptr< GEOSGeometry, GeosDeleter > unique_ptr
Scoped GEOS pointer.
void calculateInfo(bool curvedLabeling, QFontMetricsF *fm, const QgsMapToPixel *xform, double fontScale, double maxinangle, double maxoutangle)
calculate data for info(). setDefinedFont() must have been called already.
QFont definedFont()
Font to be used for rendering.
QString text(int partId) const
Returns the text component corresponding to a specified label part.
The QgsLabelFeature class describes a feature that should be used within the labeling engine...
QFont mDefinedFont
Font for rendering.
QFontMetricsF * labelFontMetrics()
Metrics of the font for rendering.
void setDataDefinedValues(const QMap< QgsPalLayerSettings::Property, QVariant > &values)
Sets data-defined values.