QGIS API Documentation
3.0.2-Girona (307d082)
|
Registry of color schemes. More...
#include <qgscolorschemeregistry.h>
Public Member Functions | |
QgsColorSchemeRegistry ()=default | |
Constructor for an empty color scheme registry. More... | |
virtual | ~QgsColorSchemeRegistry () |
void | addColorScheme (QgsColorScheme *scheme) |
Adds a color scheme to the registry. More... | |
void | addDefaultSchemes () |
Adds all default color schemes to this color scheme. More... | |
void | addUserSchemes () |
Creates schemes for all gpl palettes in the user's palettes folder. More... | |
void | populateFromInstance () |
Adds all color schemes from the global instance to this color scheme. More... | |
bool | removeColorScheme (QgsColorScheme *scheme) |
Removes all matching color schemes from the registry. More... | |
QList< QgsColorScheme * > | schemes () const |
Returns all color schemes in the registry. More... | |
QList< QgsColorScheme * > | schemes (const QgsColorScheme::SchemeFlag flag) const |
Returns all color schemes in the registry which have a specified flag set. More... | |
template<class T > | |
void | schemes (QList< T *> &schemeList) |
Return color schemes of a specific type. More... | |
Registry of color schemes.
A registry of QgsColorScheme color schemes. This class can be created directly, or accessed via a QgsApplication::colorSchemeRegistry().
Definition at line 34 of file qgscolorschemeregistry.h.
|
default |
Constructor for an empty color scheme registry.
|
virtual |
Definition at line 25 of file qgscolorschemeregistry.cpp.
void QgsColorSchemeRegistry::addColorScheme | ( | QgsColorScheme * | scheme | ) |
Adds a color scheme to the registry.
Ownership of the scheme is transferred to the registry.
scheme | color scheme to add |
Definition at line 71 of file qgscolorschemeregistry.cpp.
void QgsColorSchemeRegistry::addDefaultSchemes | ( | ) |
Adds all default color schemes to this color scheme.
Definition at line 44 of file qgscolorschemeregistry.cpp.
void QgsColorSchemeRegistry::addUserSchemes | ( | ) |
Creates schemes for all gpl palettes in the user's palettes folder.
Definition at line 53 of file qgscolorschemeregistry.cpp.
void QgsColorSchemeRegistry::populateFromInstance | ( | ) |
Adds all color schemes from the global instance to this color scheme.
Definition at line 31 of file qgscolorschemeregistry.cpp.
bool QgsColorSchemeRegistry::removeColorScheme | ( | QgsColorScheme * | scheme | ) |
Removes all matching color schemes from the registry.
scheme | color scheme to remove |
Definition at line 101 of file qgscolorschemeregistry.cpp.
QList< QgsColorScheme * > QgsColorSchemeRegistry::schemes | ( | ) | const |
Returns all color schemes in the registry.
Definition at line 76 of file qgscolorschemeregistry.cpp.
QList< QgsColorScheme * > QgsColorSchemeRegistry::schemes | ( | const QgsColorScheme::SchemeFlag | flag | ) | const |
Returns all color schemes in the registry which have a specified flag set.
flag | flag to match |
Definition at line 87 of file qgscolorschemeregistry.cpp.
|
inline |
Return color schemes of a specific type.
schemeList | destination list for matching schemes |
Definition at line 106 of file qgscolorschemeregistry.h.