messageviewer
#include <htmlquotecolorer.h>
Public Member Functions | |
HTMLQuoteColorer () | |
QString | process (const QString &htmlSource, QString &extraHead) |
void | setEnableHtmlQuoteColorer (bool enabled) |
void | setQuoteColor (unsigned int level, const QColor &color) |
Detailed Description
Little helper class that takes a HTML source as input and finds all lines that are quoted with '>' or '|'.
The HTML text is then modified so that the quoted lines appear in the defined quote colors.
Definition at line 31 of file htmlquotecolorer.h.
Constructor & Destructor Documentation
|
explicit |
Definition at line 34 of file htmlquotecolorer.cpp.
Member Function Documentation
Do the work and add nice colors to the HTML.
- Parameters
-
htmlSource the input HTML code
- Returns
- the modified HTML code, without any <body>, <html> or <head> tags
Definition at line 44 of file htmlquotecolorer.cpp.
void HTMLQuoteColorer::setEnableHtmlQuoteColorer | ( | bool | enabled | ) |
Definition at line 39 of file htmlquotecolorer.cpp.
void HTMLQuoteColorer::setQuoteColor | ( | unsigned int | level, |
const QColor & | color | ||
) |
Sets the quote color of the specific leve.
This class supports 3 levels, from 0 to 2. Level 2 is the most quoted, with three quote signs in front of the line, and level 0 is the least quoted, with one quote sign in front of the line.
If you don't call this, the color of the quoting will be black.
Definition at line 154 of file htmlquotecolorer.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:32:46 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.