GNU Octave
3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
|
A single character in the terminal which consists of a unicode character value, foreground and background colors and a set of rendition attributes which specify how it should be drawn. More...
#include "Character.h"
Public Member Functions | |
Character (quint16 _c= ' ', CharacterColor _f=CharacterColor(COLOR_SPACE_DEFAULT, DEFAULT_FORE_COLOR), CharacterColor _b=CharacterColor(COLOR_SPACE_DEFAULT, DEFAULT_BACK_COLOR), quint8 _r=0) | |
Constructs a new character. | |
bool | isBold (const ColorEntry *base) const |
Returns true if this character should always be drawn in bold when it is drawn with the specified palette , independent of whether or not the character has the RE_BOLD rendition flag. | |
bool | isTransparent (const ColorEntry *palette) const |
Returns true if this character has a transparent background when it is drawn with the specified palette . |
Public Attributes | |
union { | |
quint16 character | |
The unicode character value for this character. | |
quint16 charSequence | |
Experimental addition which allows a single Character instance to contain more than one unicode character. | |
}; | |
CharacterColor | backgroundColor |
The color used to draw this character's background. | |
CharacterColor | foregroundColor |
The foreground color used to draw this character. | |
quint8 | rendition |
A combination of RENDITION flags which specify options for drawing the character. |
Friends | |
bool | operator!= (const Character &a, const Character &b) |
Compares two characters and returns true if they have different unicode character values, renditions or colors. | |
bool | operator== (const Character &a, const Character &b) |
Compares two characters and returns true if they have the same unicode character value, rendition and colors. |
A single character in the terminal which consists of a unicode character value, foreground and background colors and a set of rendition attributes which specify how it should be drawn.
Definition at line 55 of file Character.h.
|
inline |
Constructs a new character.
_c | The unicode character value of this character. |
_f | The foreground color used to draw the character. |
_b | The color used to draw the character's background. |
_r | A set of rendition flags which specify how this character is to be drawn. |
Definition at line 66 of file Character.h.
|
inline |
Returns true if this character should always be drawn in bold when it is drawn with the specified palette
, independent of whether or not the character has the RE_BOLD rendition flag.
Definition at line 142 of file Character.h.
References CharacterColor::_colorSpace, CharacterColor::_u, CharacterColor::_v, backgroundColor, BASE_COLORS, ColorEntry::bold, COLOR_SPACE_DEFAULT, and COLOR_SPACE_SYSTEM.
Referenced by TerminalView::drawCharacters().
|
inline |
Returns true if this character has a transparent background when it is drawn with the specified palette
.
Definition at line 134 of file Character.h.
References CharacterColor::_colorSpace, CharacterColor::_u, CharacterColor::_v, backgroundColor, BASE_COLORS, COLOR_SPACE_DEFAULT, COLOR_SPACE_SYSTEM, and ColorEntry::transparent.
Compares two characters and returns true if they have different unicode character values, renditions or colors.
Definition at line 126 of file Character.h.
Compares two characters and returns true if they have the same unicode character value, rendition and colors.
Definition at line 118 of file Character.h.
union { ... } |
CharacterColor Character::backgroundColor |
The color used to draw this character's background.
Definition at line 92 of file Character.h.
Referenced by TerminalView::clearImage(), HTMLDecoder::decodeLine(), TerminalView::drawCharacters(), TerminalView::drawContents(), TerminalView::drawTextFragment(), isBold(), isTransparent(), operator!=(), operator==(), Screen::reverseRendition(), Screen::ShowCharacter(), and TerminalView::updateImage().
quint16 Character::character |
The unicode character value for this character.
Definition at line 75 of file Character.h.
Referenced by TerminalView::clearImage(), TerminalView::drawContents(), operator!=(), operator==(), Screen::ShowCharacter(), and TerminalView::updateImage().
quint16 Character::charSequence |
Experimental addition which allows a single Character instance to contain more than one unicode character.
charSequence is a hash code which can be used to look up the unicode character sequence in the ExtendedCharTable used to create the sequence.
Definition at line 83 of file Character.h.
CharacterColor Character::foregroundColor |
The foreground color used to draw this character.
Definition at line 90 of file Character.h.
Referenced by TerminalView::clearImage(), HTMLDecoder::decodeLine(), TerminalView::drawCharacters(), TerminalView::drawContents(), TerminalView::drawTextFragment(), operator!=(), operator==(), TerminalView::paintFilters(), Screen::reverseRendition(), Screen::ShowCharacter(), and TerminalView::updateImage().
quint8 Character::rendition |
A combination of RENDITION flags which specify options for drawing the character.
Definition at line 87 of file Character.h.
Referenced by TerminalView::clearImage(), HTMLDecoder::decodeLine(), TerminalView::drawCharacters(), TerminalView::drawContents(), TerminalView::drawLineCharString(), TerminalView::drawTextFragment(), Screen::getImage(), operator!=(), operator==(), Screen::ShowCharacter(), and TerminalView::updateImage().