Class: QgsUserColorScheme

class qgis.core.QgsUserColorScheme(filename: str)

Bases: QgsGplColorScheme

Constructs a new user color scheme, using a specified gpl palette file

Parameters

filename (str) – filename of gpl palette file stored in the users “palettes” folder

QgsUserColorScheme(QgsUserColorScheme)

A color scheme which stores its colors in a gpl palette file within the “palettes” subfolder off the user’s QGIS settings folder.

Methods

clone

rtype

QgsUserColorScheme

erase

Erases the associated gpl palette file from the users “palettes” folder

flags

rtype

QgsColorScheme.SchemeFlags

gplFilePath

rtype

str

isEditable

rtype

bool

schemeName

rtype

str

setName

Sets the name for the scheme

setShowSchemeInMenu

Sets whether a this scheme should be shown in color button menus.

clone(self) → QgsUserColorScheme
Return type

QgsUserColorScheme

erase(self) → bool

Erases the associated gpl palette file from the users “palettes” folder

Return type

bool

Returns

True if erase was successful

flags(self) → QgsColorScheme.SchemeFlags
Return type

QgsColorScheme.SchemeFlags

gplFilePath(self) → str
Return type

str

isEditable(self) → bool
Return type

bool

schemeName(self) → str
Return type

str

setName(self, name: str)

Sets the name for the scheme

Parameters

name (str) – new name

setShowSchemeInMenu(self, show: bool)

Sets whether a this scheme should be shown in color button menus.

Parameters

show (bool) – set to True to show in color button menus, or False to hide from menus

New in version 3.0.