KSyntaxHighlighting
themedata.cpp
99 QJsonDocument jsonDoc = QJsonDocument::fromJson(jsonData.sliced(start, (end + 1) - start), &parseError);
133 qCWarning(Log) << "Failed to parse theme file" << m_filePath << ":" << parseError.errorString();
143 m_textStyles[i] = readThemeData(textStyles.value(QLatin1String(metaEnumStyle.key(i))).toObject());
156 m_editorColors[Theme::BackgroundColor] = readColor(editorColors.value(QLatin1String("background-color")));
157 m_editorColors[Theme::TextSelection] = readColor(editorColors.value(QLatin1String("selection")));
158 m_editorColors[Theme::CurrentLine] = readColor(editorColors.value(QLatin1String("current-line")));
159 m_editorColors[Theme::SearchHighlight] = readColor(editorColors.value(QLatin1String("search-highlight")));
160 m_editorColors[Theme::ReplaceHighlight] = readColor(editorColors.value(QLatin1String("replace-highlight")));
161 m_editorColors[Theme::BracketMatching] = readColor(editorColors.value(QLatin1String("bracket-matching")));
163 m_editorColors[Theme::SpellChecking] = readColor(editorColors.value(QLatin1String("spell-checking")));
164 m_editorColors[Theme::IndentationLine] = readColor(editorColors.value(QLatin1String("indentation-line")));
165 m_editorColors[Theme::IconBorder] = readColor(editorColors.value(QLatin1String("icon-border")));
166 m_editorColors[Theme::CodeFolding] = readColor(editorColors.value(QLatin1String("code-folding")));
167 m_editorColors[Theme::LineNumbers] = readColor(editorColors.value(QLatin1String("line-numbers")));
168 m_editorColors[Theme::CurrentLineNumber] = readColor(editorColors.value(QLatin1String("current-line-number")));
169 m_editorColors[Theme::WordWrapMarker] = readColor(editorColors.value(QLatin1String("word-wrap-marker")));
170 m_editorColors[Theme::ModifiedLines] = readColor(editorColors.value(QLatin1String("modified-lines")));
171 m_editorColors[Theme::SavedLines] = readColor(editorColors.value(QLatin1String("saved-lines")));
173 m_editorColors[Theme::MarkBookmark] = readColor(editorColors.value(QLatin1String("mark-bookmark")));
174 m_editorColors[Theme::MarkBreakpointActive] = readColor(editorColors.value(QLatin1String("mark-breakpoint-active")));
175 m_editorColors[Theme::MarkBreakpointReached] = readColor(editorColors.value(QLatin1String("mark-breakpoint-reached")));
176 m_editorColors[Theme::MarkBreakpointDisabled] = readColor(editorColors.value(QLatin1String("mark-breakpoint-disabled")));
177 m_editorColors[Theme::MarkExecution] = readColor(editorColors.value(QLatin1String("mark-execution")));
178 m_editorColors[Theme::MarkWarning] = readColor(editorColors.value(QLatin1String("mark-warning")));
180 m_editorColors[Theme::TemplateBackground] = readColor(editorColors.value(QLatin1String("template-background")));
181 m_editorColors[Theme::TemplatePlaceholder] = readColor(editorColors.value(QLatin1String("template-placeholder")));
182 m_editorColors[Theme::TemplateFocusedPlaceholder] = readColor(editorColors.value(QLatin1String("template-focused-placeholder")));
183 m_editorColors[Theme::TemplateReadOnlyPlaceholder] = readColor(editorColors.value(QLatin1String("template-read-only-placeholder")));
272 Q_ASSERT(static_cast<int>(role) >= 0 && static_cast<int>(role) <= static_cast<int>(Theme::TemplateReadOnlyPlaceholder));
276TextStyleData ThemeData::textStyleOverride(const QString &definitionName, const QString &attributeName) const
EditorColorRole
Editor color roles, used to paint line numbers, editor background etc.
Definition theme.h:158
@ IndentationLine
Color used to draw vertical indentation levels, typically a line.
Definition theme.h:176
@ CodeFolding
Background colors for code folding regions in the text area, as well as code folding indicators in th...
Definition theme.h:181
@ TemplateFocusedPlaceholder
Background color for the currently active placeholder in text templates.
Definition theme.h:219
@ TemplateReadOnlyPlaceholder
Background color for read-only placeholders in text templates.
Definition theme.h:221
@ ReplaceHighlight
Background color for replaced text for a search & replace action.
Definition theme.h:168
@ BracketMatching
Background color for matching bracket pairs (including quotes)
Definition theme.h:170
@ TemplatePlaceholder
Background color for all editable placeholders in text templates.
Definition theme.h:216
@ WordWrapMarker
Color used in the icon border to indicate dynamically wrapped lines.
Definition theme.h:191
TextStyle
Default styles that can be referenced from syntax definition XML files.
Definition theme.h:75
Q_SCRIPTABLE Q_NOREPLY void start()
const QList< QKeySequence > & end()
Syntax highlighting engine for Kate syntax definitions.
Definition abstracthighlighter.h:17
qsizetype indexOf(QByteArrayView bv, qsizetype from) const const
QByteArray sliced(qsizetype pos) const const
bool isWritable() const const
ReadOnly
QJsonDocument fromJson(const QByteArray &json, QJsonParseError *error)
QJsonObject object() const const
iterator begin()
bool contains(QLatin1StringView key) const const
iterator end()
QJsonValue value(QLatin1StringView key) const const
NoError
QString errorString() const const
bool isBool() const const
bool isString() const const
bool toBool(bool defaultValue) const const
int toInt(int defaultValue) const const
QJsonObject toObject() const const
QString toString() const const
QMetaEnum fromType()
bool isEmpty() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:03:33 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:03:33 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.