[Qt-interest] Stacking / Multiple QSyntaxHighlighter on one document?

Wilhelm wilhelm.meier at fh-kl.de
Mon Jun 6 07:23:47 CEST 2011


Hi,

if I understand the implementation of QSyntaxHighlighter correct, it
should be possible to install more than one highlighter instances onto
one document, e.g. one generic highlighter for code editing which does
parenthesis matching, and then one for a specific language.

But there seems no way to add more than one QTextBlockUserData object
for one QTextBlock. So if I install more than one highlighter using
QTextBlockUserData the second one destroys the user data of the first one.

Any chance to get that right?

-- 
Wilhelm




More information about the Qt-interest-old mailing list