Public Member Functions | |
CGlSlHighlighter (QTextDocument *doc) | |
Constructs a GLSL syntax highlighter object. | |
Protected Member Functions | |
void | highlightBlock (const QString &text) |
Does actual highlighting. | |
Classes | |
struct | highlightRule_s |
This is mainly the modified syntax highlighter example from the Qt toolkit. Because GLSL has really many special worlds (keyworlds, built-in uniforms, attributes, ... ) this syntax highlighter operates quite slow. A possible improvement would be to reduce the number of supported keywords, but that would confuse the user.
CGlSlHighlighter::CGlSlHighlighter | ( | QTextDocument * | doc | ) |
Constructs a GLSL syntax highlighter object.
doc | Document to highlight. |
void CGlSlHighlighter::highlightBlock | ( | const QString & | text | ) | [protected] |
Does actual highlighting.
See Qt documentation for details.