QGIS API Documentation
3.14.0-Pi (9f7028fd23)
|
Go to the documentation of this file.
80 qDeleteAll( mMetadata );
85 if ( !metadata || mMetadata.contains( metadata->
name() ) )
88 mMetadata[metadata->
name()] = metadata;
95 return mMetadata.value( name );
121 if ( !mMetadata.contains( name ) )
124 return mMetadata[name]->createSymbolLayer( properties );
129 if ( !mMetadata.contains( name ) )
132 return mMetadata[name]->createSymbolLayerFromSld( element );
137 if ( !mMetadata.contains( name ) )
140 mMetadata[name]->resolvePaths( properties, pathResolver, saving );
146 QMap<QString, QgsSymbolLayerAbstractMetadata *>::ConstIterator it = mMetadata.constBegin();
147 for ( ; it != mMetadata.constEnd(); ++it )
150 lst.append( it.key() );
static QgsSymbolLayer * createFromSld(QDomElement &element)
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsSimpleFillSymbolLayer using the specified properties map containing symbol propertie...
static QgsSymbolLayer * createFromSld(QDomElement &element)
Creates a new QgsMarkerLineSymbolLayer from an SLD XML DOM element.
static QgsSymbolLayer * createFromSld(QDomElement &element)
Creates a new QgsLinePatternFillSymbolLayer from a SLD element.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Create a new QgsArrowSymbolLayer.
static void resolvePaths(QgsStringMap &properties, const QgsPathResolver &pathResolver, bool saving)
Turns relative paths in properties map to absolute when reading and vice versa when writing.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsSimpleLineSymbolLayer, using the settings serialized in the properties map (correspo...
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Create a new QgsMaskMarkerSymbolLayer.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsMarkerLineSymbolLayer, using the settings serialized in the properties map (correspo...
void resolvePaths(const QString &name, QgsStringMap &properties, const QgsPathResolver &pathResolver, bool saving) const
Resolve paths in properties of a particular symbol layer.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsFilledMarkerSymbolLayer.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsRandomMarkerFillSymbolLayer using the specified properties map containing symbol pro...
QgsSymbolLayer * createSymbolLayerFromSld(const QString &name, QDomElement &element) const
create a new instance of symbol layer given symbol layer name and SLD
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsCentroidFillSymbolLayer using the specified properties map containing symbol propert...
static QgsSymbolLayer * createFromSld(QDomElement &element)
Creates a new QgsSimpleLineSymbolLayer from an SLD XML DOM element.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsSimpleMarkerSymbolLayer.
bool addSymbolLayerType(QgsSymbolLayerAbstractMetadata *metadata)
register a new symbol layer type. Takes ownership of the metadata instance.
static QgsSymbolLayer * createFromSld(QDomElement &element)
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsSVGFillSymbolLayer from a properties map.
static void resolvePaths(QgsStringMap &properties, const QgsPathResolver &pathResolver, bool saving)
Turns relative paths in properties map to absolute when reading and vice versa when writing.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
static QgsSymbolLayer * createFromSld(QDomElement &element)
static QgsSymbolLayer * createFromSld(QDomElement &element)
Creates a new QgsFontMarkerSymbolLayer from an SLD XML element.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsRasterFillSymbolLayer from a properties map.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
QStringList symbolLayersForType(QgsSymbol::SymbolType type)
Returns a list of available symbol layers for a specified symbol type.
QgsSymbolLayer * createSymbolLayer(const QString &name, const QgsStringMap &properties=QgsStringMap()) const
create a new instance of symbol layer given symbol layer name and properties
static QgsSymbolLayer * defaultSymbolLayer(QgsSymbol::SymbolType type)
create a new instance of symbol layer for specified symbol type with default settings
static QgsSymbolLayer * createFromSld(QDomElement &element)
Creates a new QgsSimpleMarkerSymbolLayer from an SLD XML element.
QMap< QString, QString > QgsStringMap
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsFontMarkerSymbolLayer from a property map (see properties())
static void resolvePaths(QgsStringMap &properties, const QgsPathResolver &pathResolver, bool saving)
Turns relative paths in properties map to absolute when reading and vice versa when writing.
~QgsSymbolLayerRegistry()
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsHashedLineSymbolLayer, using the settings serialized in the properties map (correspo...
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsGradientFillSymbolLayer using the specified properties map containing symbol propert...
SymbolType
Type of the symbol.
static QgsSymbolLayer * create(const QgsStringMap &properties)
static QgsSymbolLayer * createFromSld(QDomElement &element)
static QgsSymbolLayer * createFromSld(QDomElement &element)
Creates a new QgsSVGFillSymbolLayer from a SLD element.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a raster marker symbol layer from a string map of properties.
static QgsSymbolLayer * createFromSld(QDomElement &element)
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsPointPatternFillSymbolLayer using the specified properties map containing symbol pro...
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsLinePatternFillSymbolLayer from a properties map.
static QgsSymbolLayer * create(const QgsStringMap &properties=QgsStringMap())
Creates a new QgsShapeburstFillSymbolLayer using the specified properties map containing symbol prope...
QgsSymbolLayerAbstractMetadata * symbolLayerMetadata(const QString &name) const
Returns metadata for specified symbol layer. Returns nullptr if not found.