QGIS API Documentation  3.6.0-Noosa (5873452)
Public Member Functions | Protected Attributes | List of all members
QgsSymbolLayerAbstractMetadata Class Referenceabstract

Stores metadata about one symbol layer class. More...

#include <qgssymbollayerregistry.h>

Inheritance diagram for QgsSymbolLayerAbstractMetadata:
Inheritance graph
[legend]

Public Member Functions

 QgsSymbolLayerAbstractMetadata (const QString &name, const QString &visibleName, QgsSymbol::SymbolType type)
 
virtual ~QgsSymbolLayerAbstractMetadata ()=default
 
virtual QgsSymbolLayercreateSymbolLayer (const QgsStringMap &map)=0
 Create a symbol layer of this type given the map of properties. More...
 
virtual QgsSymbolLayercreateSymbolLayerFromSld (QDomElement &)
 Create a symbol layer of this type given the map of properties. More...
 
virtual QgsSymbolLayerWidgetcreateSymbolLayerWidget (QgsVectorLayer *)
 Create widget for symbol layer of this type. Can return NULL if there's no GUI. More...
 
QString name () const
 
virtual void resolvePaths (QgsStringMap &properties, const QgsPathResolver &pathResolver, bool saving)
 Resolve paths in symbol layer's properties (if there are any paths). More...
 
QgsSymbol::SymbolType type () const
 
QString visibleName () const
 

Protected Attributes

QString mName
 
QgsSymbol::SymbolType mType
 
QString mVisibleName
 

Detailed Description

Stores metadata about one symbol layer class.

Note
It's necessary to implement createSymbolLayer() function. In C++ you can use QgsSymbolLayerMetadata convenience class.

Definition at line 34 of file qgssymbollayerregistry.h.

Constructor & Destructor Documentation

◆ QgsSymbolLayerAbstractMetadata()

QgsSymbolLayerAbstractMetadata::QgsSymbolLayerAbstractMetadata ( const QString &  name,
const QString &  visibleName,
QgsSymbol::SymbolType  type 
)
inline

Definition at line 37 of file qgssymbollayerregistry.h.

◆ ~QgsSymbolLayerAbstractMetadata()

virtual QgsSymbolLayerAbstractMetadata::~QgsSymbolLayerAbstractMetadata ( )
virtualdefault

Member Function Documentation

◆ createSymbolLayer()

virtual QgsSymbolLayer* QgsSymbolLayerAbstractMetadata::createSymbolLayer ( const QgsStringMap map)
pure virtual

Create a symbol layer of this type given the map of properties.

Implemented in QgsSymbolLayerMetadata.

◆ createSymbolLayerFromSld()

virtual QgsSymbolLayer* QgsSymbolLayerAbstractMetadata::createSymbolLayerFromSld ( QDomElement &  )
inlinevirtual

Create a symbol layer of this type given the map of properties.

Reimplemented in QgsSymbolLayerMetadata.

Definition at line 54 of file qgssymbollayerregistry.h.

◆ createSymbolLayerWidget()

virtual QgsSymbolLayerWidget* QgsSymbolLayerAbstractMetadata::createSymbolLayerWidget ( QgsVectorLayer )
inlinevirtual

Create widget for symbol layer of this type. Can return NULL if there's no GUI.

Reimplemented in QgsSymbolLayerMetadata.

Definition at line 52 of file qgssymbollayerregistry.h.

◆ name()

QString QgsSymbolLayerAbstractMetadata::name ( ) const
inline

Definition at line 45 of file qgssymbollayerregistry.h.

◆ resolvePaths()

virtual void QgsSymbolLayerAbstractMetadata::resolvePaths ( QgsStringMap properties,
const QgsPathResolver pathResolver,
bool  saving 
)
inlinevirtual

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

Since
QGIS 3.0

Reimplemented in QgsSymbolLayerMetadata.

Definition at line 64 of file qgssymbollayerregistry.h.

◆ type()

QgsSymbol::SymbolType QgsSymbolLayerAbstractMetadata::type ( ) const
inline

Definition at line 47 of file qgssymbollayerregistry.h.

◆ visibleName()

QString QgsSymbolLayerAbstractMetadata::visibleName ( ) const
inline

Definition at line 46 of file qgssymbollayerregistry.h.

Member Data Documentation

◆ mName

QString QgsSymbolLayerAbstractMetadata::mName
protected

Definition at line 72 of file qgssymbollayerregistry.h.

◆ mType

QgsSymbol::SymbolType QgsSymbolLayerAbstractMetadata::mType
protected

Definition at line 74 of file qgssymbollayerregistry.h.

◆ mVisibleName

QString QgsSymbolLayerAbstractMetadata::mVisibleName
protected

Definition at line 73 of file qgssymbollayerregistry.h.


The documentation for this class was generated from the following file: