Details
-
Suggestion
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
5.15.2
-
None
-
macOS 10.15.7
Description
Calling rehighlight() on a QSyntaxHighlighter ends up calling QTextDocumentPrivate::contentsChanged(), which marks my document window as dirty. Rehighlighting shouldn't mark the text document as changed, it seems to me. Note that this is being triggered for me on macOS by the user switching from light mode to dark mode; I want different highlighting colors to be used in dark mode, so I call rehighlight(). But the document becomes dirty as a result. I think I will have to work around this by setting a flag, around my call to rehighlight(), that prevents the document from dirtying inside that call, which is kinda gross.