QPythonHighlighter.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 // QCodeEditor
4 #include <QStyleSyntaxHighlighter> // Required for inheritance
5 #include <QHighlightRule>
6 #include <QHighlightBlockRule>
7 
8 // Qt
9 #include <QRegularExpression>
10 #include <QVector>
11 
12 class QSyntaxStyle;
13 
19 {
20  Q_OBJECT
21 public:
22 
27  explicit QPythonHighlighter(QTextDocument* document=nullptr);
28 
29 protected:
30  void highlightBlock(const QString& text) override;
31 
32 private:
33 
36 
37  QRegularExpression m_includePattern;
38  QRegularExpression m_functionPattern;
39  QRegularExpression m_defTypePattern;
40 };
41 
QRegularExpression m_defTypePattern
QVector< QHighlightRule > m_highlightRules
Class, that describes Qt style parser for QCodeEditor.
Class, that descrubes highlighter with syntax style.
QVector< QHighlightBlockRule > m_highlightBlockRules
QPythonHighlighter(QTextDocument *document=nullptr)
Constructor.
QRegularExpression m_functionPattern
void highlightBlock(const QString &text) override
QRegularExpression m_includePattern
Class, that describes Glsl code highlighter.


plotjuggler
Author(s): Davide Faconti
autogenerated on Mon Jun 19 2023 03:01:38