lib
ElementType Class Reference
#include <elementtype.h>
Inheritance diagram for ElementType:

Detailed Description
Basis of all types.Types make up a hierarchy that describes the semantic of the sequence.
Definition at line 52 of file elementtype.h.
Public Member Functions | |
ElementType (SequenceParser *parser) | |
virtual | ~ElementType () |
virtual bool | isInvisible (const TextElement &) const |
virtual QString | text (SequenceElement *seq) const |
uint | start () const |
uint | end () const |
virtual luPt | getSpaceBefore (const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (MultiElementType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (OperatorType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (RelationType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (PunctuationType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (BracketType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (ComplexElementType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual luPt | getSpaceAfter (InnerElementType *type, const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
virtual QFont | getFont (const ContextStyle &context) |
virtual void | setUpPainter (const ContextStyle &context, QPainter &painter) |
virtual void | output () |
void | append (ElementType *) |
ElementType * | getPrev () const |
virtual void | saveMathML (SequenceElement *se, QDomDocument &doc, QDomElement de, bool oasisFormat=false) |
virtual bool | multiElement () const |
Static Public Member Functions | |
static int | getEvilDestructionCount () |
Protected Member Functions | |
void | setStart (uint start) |
void | setEnd (uint end) |
luPt | thinSpaceIfNotScript (const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
luPt | mediumSpaceIfNotScript (const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
luPt | thickSpaceIfNotScript (const ContextStyle &context, ContextStyle::TextStyle tstyle, double factor) |
Member Function Documentation
virtual bool ElementType::isInvisible | ( | const TextElement & | ) | const [inline, virtual] |
QString ElementType::text | ( | SequenceElement * | seq | ) | const [virtual] |
- Returns:
- the spanned text.
seq must be the original parent sequence.
Reimplemented in MultiElementType.
Definition at line 93 of file elementtype.cc.
uint ElementType::start | ( | ) | const [inline] |
uint ElementType::end | ( | ) | const [inline] |
- Returns:
- the position of the first character after the typed element
Definition at line 76 of file elementtype.h.
luPt ElementType::getSpaceBefore | ( | const ContextStyle & | context, | |
ContextStyle::TextStyle | tstyle, | |||
double | factor | |||
) | [virtual] |
- Returns:
- the space to be left before each char for the given style and font size.
Reimplemented in MultiElementType, OperatorType, RelationType, PunctuationType, BracketType, ComplexElementType, and InnerElementType.
Definition at line 103 of file elementtype.cc.
QFont ElementType::getFont | ( | const ContextStyle & | context | ) | [virtual] |
- Returns:
- the font to be used for this kind of element
Reimplemented in NumberType, NameType, OperatorType, RelationType, and PunctuationType.
Definition at line 197 of file elementtype.cc.
void ElementType::setUpPainter | ( | const ContextStyle & | context, | |
QPainter & | painter | |||
) | [virtual] |
sets the painters pen to a appropriate value
Reimplemented in NumberType, OperatorType, RelationType, and PunctuationType.
Definition at line 202 of file elementtype.cc.
void ElementType::append | ( | ElementType * | ) |
The documentation for this class was generated from the following files: