CppEditor: fix highlighter tests

amends 9091c99429

Change-Id: Iaa64d51aa0dad1d63c88a51bfa55afa2367e65ed
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
David Schulz
2023-06-15 13:28:33 +02:00
parent db8842a0d4
commit 5ba10671da
3 changed files with 11 additions and 2 deletions

View File

@@ -869,6 +869,13 @@ QTextCharFormat SyntaxHighlighter::whitespacified(const QTextCharFormat &fmt)
return format;
}
QTextCharFormat SyntaxHighlighter::asSyntaxHighlight(const QTextCharFormat &fmt)
{
QTextCharFormat format = fmt;
format.setProperty(SyntaxHighlight, true);
return format;
}
void SyntaxHighlighter::highlightBlock(const QString &text)
{
formatSpaces(text);