TextUtils::TextUtilsSyntaxHighlighter Class
The TextUtilsSyntaxHighlighter class Author: Laurent Montel <montel@kde.org>. More...
| Header: | #include <TextUtils/TextUtilsSyntaxHighlighter> |
| CMake: | find_package(KF6TextUtils REQUIRED)target_link_libraries(mytarget PRIVATE KF6::TextUtils) |
Public Functions
| TextUtilsSyntaxHighlighter(QTextStream *stream) | |
| virtual | ~TextUtilsSyntaxHighlighter() override |
| bool | allowInsertText() const |
| void | highlight(const QString &str, const QByteArray &uuid, int &blockCodeIndex) |
| void | setAllowInsertText(bool newAllowInsertText) |
Static Public Members
| QString | copyHref() |
| QString | insertBlockTextHref() |
Reimplemented Protected Functions
| virtual void | applyFormat(int offset, int length, const KSyntaxHighlighting::Format &format) override |
Detailed Description
Member Function Documentation
[explicit] TextUtilsSyntaxHighlighter::TextUtilsSyntaxHighlighter(QTextStream *stream)
Constructor for TextUtilsSyntaxHighlighter stream The text stream to write highlighted output to
[override virtual noexcept default] TextUtilsSyntaxHighlighter::~TextUtilsSyntaxHighlighter()
Destructor for TextUtilsSyntaxHighlighter
bool TextUtilsSyntaxHighlighter::allowInsertText() const
Returns true if we display icon for inserting text Returns The Insert Text boolean
See also setAllowInsertText().
[override virtual protected] void TextUtilsSyntaxHighlighter::applyFormat(int offset, int length, const KSyntaxHighlighting::Format &format)
Applies formatting to a range of text offset The offset in the current line length The length of the text to format format The format to apply
[static] QString TextUtilsSyntaxHighlighter::copyHref()
Returns the href for the copy button Returns The href string
void TextUtilsSyntaxHighlighter::highlight(const QString &str, const QByteArray &uuid, int &blockCodeIndex)
Highlights a string of text str The text to highlight uuid The unique identifier for the text block blockCodeIndex The index of the code block
[static] QString TextUtilsSyntaxHighlighter::insertBlockTextHref()
Returns the href for the insert block text button Returns The href string
void TextUtilsSyntaxHighlighter::setAllowInsertText(bool newAllowInsertText)
setAllowInsertText newAllowInsertText
See also allowInsertText().