QGIS API Documentation
3.16.0-Hannover (43b64b13f3)
|
Go to the documentation of this file.
147 if ( mColorSchemes.contains(
scheme.
id() ) )
156 if ( !mColorSchemes.contains(
id ) )
159 mColorSchemes.remove(
id );
165 return mColorSchemes.keys();
170 if ( !mColorSchemes.contains(
id ) )
171 return mColorSchemes.value( QStringLiteral(
"default" ) );
173 return mColorSchemes.value(
id );
@ SelectionForeground
Selection foreground color.
@ MarginForeground
Margin foreground color.
@ CaretLine
Caret line color.
@ Default
Default text color.
@ FoldIconForeground
Fold icon foreground color.
@ CommentLine
Line comment color.
QgsCodeEditorColorScheme scheme(const QString &id) const
Returns the color scheme with matching id.
Defines a color scheme for use in QgsCodeEditor widgets.
@ Operator
Operator color.
QgsCodeEditorColorSchemeRegistry()
Constructor for a color scheme registry.
@ SingleQuote
Single quote color.
@ SelectionBackground
Selection background color.
@ DoubleQuote
Double quote color.
@ MarginBackground
Margin background color.
QStringList schemes() const
Returns a list of the QgsCodeEditorColorScheme::id() values for all registered color schemes.
bool addColorScheme(const QgsCodeEditorColorScheme &scheme)
Adds a color scheme to the registry.
QString id() const
Returns the ID of the color scheme, which is a unique, non-translated identifier for the scheme.
@ MatchedBraceBackground
Matched brace background color.
@ Decoration
Decoration color.
@ CommentBlock
Comment block color.
@ IndentationGuide
Indentation guide line.
bool removeColorScheme(const QString &id)
Removes the color scheme with matching id from the registry.
@ TripleSingleQuote
Triple single quote color.
@ Identifier
Identifier color.
@ TripleDoubleQuote
Triple double quote color.
@ QuotedOperator
Quoted operator color.
@ MatchedBraceForeground
Matched brace foreground color.
@ QuotedIdentifier
Quoted identifier color.
void setColors(const QMap< ColorRole, QColor > &colors)
Sets all colors for the scheme.
@ Background
Background color.
@ ErrorBackground
Error background color.
@ FoldIconHalo
Fold icon halo color.