QGIS API Documentation
2.8.2-Wien
|
A color scheme which stores its colors in a gpl palette file within the "palettes" subfolder off the user's QGIS settings folder. More...
#include <qgscolorscheme.h>
Public Member Functions | |
QgsUserColorScheme (const QString &filename) | |
Constructs a new user color scheme, using a specified gpl palette file. | |
virtual | ~QgsUserColorScheme () |
virtual QgsColorScheme * | clone () const override |
Clones a color scheme. | |
bool | erase () |
Erases the associated gpl palette file from the users "palettes" folder. | |
virtual bool | isEditable () const override |
Returns whether the color scheme is editable. | |
virtual QString | schemeName () const override |
Gets the name for the color scheme. | |
void | setName (const QString &name) |
Sets the name for the scheme. | |
![]() | |
QgsGplColorScheme () | |
virtual | ~QgsGplColorScheme () |
virtual QgsNamedColorList | fetchColors (const QString &context=QString(), const QColor &baseColor=QColor()) override |
Gets a list of colors from the scheme. | |
virtual bool | setColors (const QgsNamedColorList &colors, const QString &context=QString(), const QColor &baseColor=QColor()) override |
Sets the colors for the scheme. | |
![]() | |
QgsColorScheme () | |
virtual | ~QgsColorScheme () |
virtual SchemeFlags | flags () const |
Returns the current flags for the color scheme. |
Protected Member Functions | |
virtual QString | gplFilePath () override |
Returns the file path for the associated gpl palette file. |
Protected Attributes | |
QString | mFilename |
QString | mName |
Additional Inherited Members | |
![]() | |
enum | SchemeFlag { ShowInColorDialog = 0x01, ShowInColorButtonMenu = 0x02, ShowInAllContexts = ShowInColorDialog | ShowInColorButtonMenu } |
Flags for controlling behaviour of color scheme. More... |
A color scheme which stores its colors in a gpl palette file within the "palettes" subfolder off the user's QGIS settings folder.
Definition at line 136 of file qgscolorscheme.h.
QgsUserColorScheme::QgsUserColorScheme | ( | const QString & | filename | ) |
Constructs a new user color scheme, using a specified gpl palette file.
filename | filename of gpl palette file stored in the users "palettes" folder |
Definition at line 293 of file qgscolorscheme.cpp.
|
virtual |
Definition at line 325 of file qgscolorscheme.cpp.
|
overridevirtual |
Clones a color scheme.
Implements QgsColorScheme.
Definition at line 335 of file qgscolorscheme.cpp.
bool QgsUserColorScheme::erase | ( | ) |
Erases the associated gpl palette file from the users "palettes" folder.
Definition at line 340 of file qgscolorscheme.cpp.
|
overrideprotectedvirtual |
Returns the file path for the associated gpl palette file.
Implements QgsGplColorScheme.
Definition at line 352 of file qgscolorscheme.cpp.
|
inlineoverridevirtual |
Returns whether the color scheme is editable.
Reimplemented from QgsColorScheme.
Definition at line 151 of file qgscolorscheme.h.
|
overridevirtual |
Gets the name for the color scheme.
Implements QgsColorScheme.
Definition at line 330 of file qgscolorscheme.cpp.
|
inline |
Sets the name for the scheme.
name | new name |
Definition at line 156 of file qgscolorscheme.h.
|
protected |
Definition at line 167 of file qgscolorscheme.h.
|
protected |
Definition at line 165 of file qgscolorscheme.h.