QGIS API Documentation
3.14.0-Pi (9f7028fd23)
|
Go to the documentation of this file.
16 #ifndef QGSTEXTFORMAT_H
17 #define QGSTEXTFORMAT_H
20 #include "qgis_core.h"
27 #include <QSharedDataPointer>
29 class QgsTextSettingsPrivate;
172 void setFont(
const QFont &font );
179 QString namedStyle()
const;
187 void setNamedStyle(
const QString &style );
202 void setSize(
double size );
241 QColor color()
const;
248 void setColor(
const QColor &color );
255 double opacity()
const;
263 void setOpacity(
double opacity );
269 QPainter::CompositionMode blendMode()
const;
276 void setBlendMode( QPainter::CompositionMode mode );
284 double lineHeight()
const;
293 void setLineHeight(
double height );
300 TextOrientation orientation()
const;
307 void setOrientation( TextOrientation orientation );
323 bool allowHtmlFormatting()
const;
339 void setAllowHtmlFormatting(
bool allow );
346 QColor previewBackgroundColor()
const;
353 void setPreviewBackgroundColor(
const QColor &color );
396 QFont toQFont() const;
409 bool containsAdvancedEffects() const;
416 bool fontFound()
const {
return mTextFontFound; }
469 static QPixmap textFormatPreviewPixmap( const
QgsTextFormat &format, QSize size, const QString &previewText = QString(),
int padding = 0 );
478 QString mTextFontFamily;
479 bool mTextFontFound = true;
481 QSharedDataPointer<QgsTextSettingsPrivate> d;
485 #endif // QGSTEXTFORMAT_H
QgsTextBufferSettings & buffer()
Returns a reference to the text buffer settings.
RenderUnit
Rendering size units.
QString resolvedFontFamily() const
Returns the family for the resolved font, ie if the specified font was not found on the system this w...
QgsTextShadowSettings shadow() const
Returns a reference to the text drop shadow settings.
QgsTextShadowSettings & shadow()
Returns a reference to the text drop shadow settings.
QgsTextMaskSettings & mask()
Returns a reference to the masking settings.
QgsTextBackgroundSettings background() const
Returns a reference to the text background settings.
@ VerticalOrientation
Horizontally oriented text.
QgsTextMaskSettings mask() const
Returns a reference to the masking settings.
void setBackground(const QgsTextBackgroundSettings &backgroundSettings)
Sets the text's background settings.q.
Struct for storing maximum and minimum scales for measurements in map units.
QgsTextBufferSettings buffer() const
Returns a reference to the text buffer settings.
A grouped map of multiple QgsProperty objects, each referenced by a integer key value.
void setBuffer(const QgsTextBufferSettings &bufferSettings)
Sets the text's buffer settings.
@ RotationBasedOrientation
Horizontally or vertically oriented text based on rotation (only available for map labeling)
void setShadow(const QgsTextShadowSettings &shadowSettings)
Sets the text's drop shadow settings.
void setMask(const QgsTextMaskSettings &maskSettings)
Sets the text's masking settings.
QgsTextBackgroundSettings & background()
Returns a reference to the text background settings.
@ HorizontalOrientation
Vertically oriented text.
TextOrientation
Text orientation.