Kactus2
Kactus2 reference guide
Loading...
Searching...
No Matches
ImportHighlighter Class Reference

Source file highlighter for import files. More...

#include <ImportHighlighter.h>

Inheritance diagram for ImportHighlighter:
Highlighter

Public Member Functions

 ImportHighlighter (QPlainTextEdit *display, QObject *parent)
 
 ~ImportHighlighter ()
 The destructor.
 
virtual void applyFontColor (QString const &text, QColor const &color)
 
virtual void applyHighlight (int beginPosition, int endPosition, QColor const &highlightColor)
 
virtual void applyHighlight (QString const &text, QColor const &highlightColor, QString const &subSection=QString())
 
- Public Member Functions inherited from Highlighter
virtual ~Highlighter ()
 The destructor.
 

Detailed Description

Source file highlighter for import files.

Definition at line 25 of file ImportHighlighter.h.

Constructor & Destructor Documentation

◆ ImportHighlighter()

ImportHighlighter::ImportHighlighter ( QPlainTextEdit * display,
QObject * parent )

The constructor.

Parameters
[in]displayThe display widget for the parsed source file content.
[in]parentThe parent object.

◆ ~ImportHighlighter()

ImportHighlighter::~ImportHighlighter ( )

The destructor.

Member Function Documentation

◆ applyFontColor()

virtual void ImportHighlighter::applyFontColor ( QString const & text,
QColor const & color )
virtual

Called when the font color of a text should be changed to the given color.

Parameters
[in]textThe text whose font to change.
[in]colorThe color of the text.

Implements Highlighter.

◆ applyHighlight() [1/2]

virtual void ImportHighlighter::applyHighlight ( int beginPosition,
int endPosition,
QColor const & highlightColor )
virtual

Called when a section should be highlighted with the given color>.

Parameters
[in]beginPositionThe beginning character index.
[in]endPositionThe end character index.
[in]highlightColorThe color of the highlight.

Implements Highlighter.

◆ applyHighlight() [2/2]

virtual void ImportHighlighter::applyHighlight ( QString const & text,
QColor const & highlightColor,
QString const & subSection = QString() )
virtual

Called when the text should be highlighted with the given color.

Parameters
[in]textThe text to highlight.
[in]highlightColorThe color of the highlight.
[in]subSectionThe current subsection containing the selected text.

Implements Highlighter.


The documentation for this class was generated from the following file: