24 #ifndef TERMINAL_CHARACTER_DECODER_H
25 #define TERMINAL_CHARACTER_DECODER_H
46 virtual void begin(QTextStream* output) = 0;
48 virtual void end() = 0;
84 virtual void begin(QTextStream* output);
118 virtual void begin(QTextStream* output);
122 void openSpan(QString& text ,
const QString& style);
unsigned char LineProperty
Describes the color of a single character in the terminal.
A single character in the terminal which consists of a unicode character value, foreground and backgr...
An entry in a terminal display's color palette.
A terminal character decoder which produces pretty HTML markup.
CharacterColor _lastBackColor
CharacterColor _lastForeColor
HTMLDecoder()
Constructs an HTML decoder using a default black-on-white color scheme.
void closeSpan(QString &text)
const ColorEntry * _colorTable
virtual void end()
End decoding.
void openSpan(QString &text, const QString &style)
virtual void decodeLine(const Character *const characters, int count, LineProperty properties)
Converts a line of terminal characters with associated properties into a text string and writes the s...
void setColorTable(const ColorEntry *table)
Sets the colour table which the decoder uses to produce the HTML colour codes in its output.
virtual void begin(QTextStream *output)
Begin decoding characters.
A terminal character decoder which produces plain text, ignoring colours and other appearance-related...
void setTrailingWhitespace(bool enable)
Set whether trailing whitespace at the end of lines should be included in the output.
virtual void decodeLine(const Character *const characters, int count, LineProperty properties)
Converts a line of terminal characters with associated properties into a text string and writes the s...
virtual void begin(QTextStream *output)
Begin decoding characters.
bool _includeTrailingWhitespace
virtual void end()
End decoding.
bool trailingWhitespace() const
Returns whether trailing whitespace at the end of lines is included in the output.
Base class for terminal character decoders.
virtual void end()=0
End decoding.
virtual void begin(QTextStream *output)=0
Begin decoding characters.
virtual void decodeLine(const Character *const characters, int count, LineProperty properties)=0
Converts a line of terminal characters with associated properties into a text string and writes the s...
virtual ~TerminalCharacterDecoder()
T::properties & properties(graphics_object obj)