QGIS API Documentation 3.43.0-Master (b1964063d82)
|
Convenience metadata class that uses static functions to create symbol layer and its widget. More...
#include <qgssymbollayerregistry.h>
Public Member Functions | |
QgsSymbolLayerMetadata (const QString &name, const QString &visibleName, Qgis::SymbolType type, QgsSymbolLayerCreateFunc pfCreate, QgsSymbolLayerCreateFromSldFunc pfCreateFromSld=nullptr, QgsSymbolLayerPathResolverFunc pfPathResolver=nullptr, QgsSymbolLayerWidgetFunc pfWidget=nullptr, QgsSymbolLayerFontResolverFunc pfFontResolver=nullptr) | |
QgsSymbolLayerCreateFromSldFunc | createFromSldFunction () const |
QgsSymbolLayerCreateFunc | createFunction () const |
QgsSymbolLayer * | createSymbolLayer (const QVariantMap &map) override |
Create a symbol layer of this type given the map of properties. | |
QgsSymbolLayer * | createSymbolLayerFromSld (QDomElement &elem) override |
Create a symbol layer of this type given the map of properties. | |
QgsSymbolLayerWidget * | createSymbolLayerWidget (QgsVectorLayer *vl) override |
Create widget for symbol layer of this type. Can return nullptr if there's no GUI. | |
QgsSymbolLayerPathResolverFunc | pathResolverFunction () const |
void | resolveFonts (const QVariantMap &properties, const QgsReadWriteContext &context) override |
Resolve fonts from the symbol layer's properties. | |
void | resolvePaths (QVariantMap &properties, const QgsPathResolver &pathResolver, bool saving) override |
Resolve paths in symbol layer's properties (if there are any paths). | |
void | setWidgetFunction (QgsSymbolLayerWidgetFunc f) |
QgsSymbolLayerWidgetFunc | widgetFunction () const |
![]() | |
QgsSymbolLayerAbstractMetadata (const QString &name, const QString &visibleName, Qgis::SymbolType type) | |
Constructor for QgsSymbolLayerAbstractMetadata. | |
virtual | ~QgsSymbolLayerAbstractMetadata ()=default |
QString | name () const |
Qgis::SymbolType | type () const |
QString | visibleName () const |
Protected Attributes | |
QgsSymbolLayerCreateFromSldFunc | mCreateFromSldFunc |
QgsSymbolLayerCreateFunc | mCreateFunc |
QgsSymbolLayerFontResolverFunc | mFontResolverFunc |
Font resolver function pointer. | |
QgsSymbolLayerPathResolverFunc | mPathResolverFunc |
QgsSymbolLayerWidgetFunc | mWidgetFunc |
![]() | |
QString | mName |
Qgis::SymbolType | mType |
QString | mVisibleName |
Convenience metadata class that uses static functions to create symbol layer and its widget.
Definition at line 109 of file qgssymbollayerregistry.h.
|
inline |
Definition at line 113 of file qgssymbollayerregistry.h.
|
inline |
Definition at line 133 of file qgssymbollayerregistry.h.
|
inline |
Definition at line 129 of file qgssymbollayerregistry.h.
|
inlineoverridevirtual |
Create a symbol layer of this type given the map of properties.
Implements QgsSymbolLayerAbstractMetadata.
Definition at line 140 of file qgssymbollayerregistry.h.
|
inlineoverridevirtual |
Create a symbol layer of this type given the map of properties.
Reimplemented from QgsSymbolLayerAbstractMetadata.
Definition at line 142 of file qgssymbollayerregistry.h.
|
inlineoverridevirtual |
Create widget for symbol layer of this type. Can return nullptr
if there's no GUI.
Reimplemented from QgsSymbolLayerAbstractMetadata.
Definition at line 141 of file qgssymbollayerregistry.h.
|
inline |
Definition at line 135 of file qgssymbollayerregistry.h.
|
inlineoverridevirtual |
Resolve fonts from the symbol layer's properties.
This tests whether the required fonts from the encoded properties are available on the system, and records warnings in the context if not.
Reimplemented from QgsSymbolLayerAbstractMetadata.
Definition at line 149 of file qgssymbollayerregistry.h.
|
inlineoverridevirtual |
Resolve paths in symbol layer's properties (if there are any paths).
When saving is true
, paths are converted from absolute to relative, when saving is false
, paths are converted from relative to absolute. This ensures that paths in project files can be relative, but in symbol layer instances the paths are always absolute
Reimplemented from QgsSymbolLayerAbstractMetadata.
Definition at line 143 of file qgssymbollayerregistry.h.
|
inline |
Definition at line 138 of file qgssymbollayerregistry.h.
|
inline |
Definition at line 131 of file qgssymbollayerregistry.h.
|
protected |
Definition at line 158 of file qgssymbollayerregistry.h.
|
protected |
Definition at line 156 of file qgssymbollayerregistry.h.
|
protected |
Font resolver function pointer.
Definition at line 166 of file qgssymbollayerregistry.h.
|
protected |
Definition at line 159 of file qgssymbollayerregistry.h.
|
protected |
Definition at line 157 of file qgssymbollayerregistry.h.