summaryrefslogtreecommitdiff
path: root/src/plugins/glsleditor/glslhighlighter.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/glsleditor/glslhighlighter.h')
-rw-r--r--src/plugins/glsleditor/glslhighlighter.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/plugins/glsleditor/glslhighlighter.h b/src/plugins/glsleditor/glslhighlighter.h
index 9038f636b3..0f5660092a 100644
--- a/src/plugins/glsleditor/glslhighlighter.h
+++ b/src/plugins/glsleditor/glslhighlighter.h
@@ -32,10 +32,10 @@
#include <texteditor/syntaxhighlighter.h>
namespace GLSLEditor {
-class GLSLTextEditorWidget;
-
namespace Internal {
+class GLSLTextEditorWidget;
+
class Highlighter : public TextEditor::SyntaxHighlighter
{
Q_OBJECT
@@ -57,18 +57,17 @@ public:
NumGLSLFormats
};
+ explicit Highlighter(QTextDocument *parent = 0);
explicit Highlighter(TextEditor::BaseTextDocument *parent);
virtual ~Highlighter();
- void setFormats(const QVector<QTextCharFormat> &formats);
-
protected:
void highlightBlock(const QString &text);
void highlightLine(const QString &text, int position, int length, const QTextCharFormat &format);
bool isPPKeyword(const QStringRef &text) const;
private:
- QTextCharFormat m_formats[NumGLSLFormats];
+ void init();
};
} // namespace Internal