#include <spaceelement.h>
Public Member Functions | |
| SpaceElement (SpaceWidth space=THIN, bool tab=false, BasicElement *parent=0) | |
| SpaceElement (const SpaceElement &) | |
| virtual SpaceElement * | clone () |
| virtual bool | accept (ElementVisitor *visitor) |
| virtual TQChar | getCharacter () const |
| virtual void | calcSizes (const ContextStyle &cstyle, ContextStyle::TextStyle tstyle, ContextStyle::IndexStyle istyle, StyleAttributes &style) |
| virtual TQString | toLatex () |
| Public Member Functions inherited from BasicElement | |
| BasicElement (BasicElement *parent=0) | |
| BasicElement (const BasicElement &) | |
| virtual bool | readOnly (const BasicElement *child) const |
| virtual FormulaElement * | formula () |
| virtual const FormulaElement * | formula () const |
| virtual TokenType | getTokenType () const |
| virtual bool | isInvisible () const |
| virtual BasicElement * | goToPos (FormulaCursor *, bool &handled, const LuPixelPoint &point, const LuPixelPoint &parentOrigin) |
| LuPixelPoint | widgetPos () |
| virtual void | dispatchFontCommand (FontCommand *) |
| virtual void | moveHome (FormulaCursor *) |
| virtual void | moveEnd (FormulaCursor *) |
| virtual void | goInside (FormulaCursor *cursor) |
| virtual void | entered (SequenceElement *) |
| virtual SequenceElement * | getMainChild () |
| virtual void | insert (FormulaCursor *, TQPtrList< BasicElement > &, Direction) |
| virtual void | remove (FormulaCursor *, TQPtrList< BasicElement > &, Direction) |
| virtual void | normalize (FormulaCursor *, Direction) |
| virtual bool | isSenseless () |
| virtual BasicElement * | getChild (FormulaCursor *, Direction=beforeCursor) |
| virtual void | selectChild (FormulaCursor *, BasicElement *) |
| virtual void | childWillVanish (FormulaCursor *, BasicElement *) |
| virtual void | registerTab (BasicElement *) |
| virtual KCommand * | buildCommand (Container *, Request *) |
| virtual KCommand * | input (Container *, TQKeyEvent *) |
| const BasicElement * | getParent () const |
| BasicElement * | getParent () |
| void | setParent (BasicElement *p) |
| luPixel | getX () const |
| luPixel | getY () const |
| void | setX (luPixel x) |
| void | setY (luPixel y) |
| luPixel | getWidth () const |
| luPixel | getHeight () const |
| void | setWidth (luPixel width) |
| void | setHeight (luPixel height) |
| luPixel | getBaseline () const |
| void | setBaseline (luPixel line) |
| luPixel | axis (const ContextStyle &style, ContextStyle::TextStyle tstyle, double factor) const |
| TQDomElement | getElementDom (TQDomDocument &doc) |
| virtual void | writeMathML (TQDomDocument &doc, TQDomNode &parent, bool oasisFormat=false) const |
| bool | buildFromDom (TQDomElement element) |
| int | buildFromMathMLDom (TQDomElement element) |
| ElementType * | getElementType () const |
| virtual void | setElementType (ElementType *t) |
| virtual void | setStyle (StyleElement *) |
Protected Member Functions | |
| virtual TQString | getTagName () const |
| virtual void | writeDom (TQDomElement element) |
| virtual bool | readAttributesFromDom (TQDomElement element) |
| virtual bool | readContentFromDom (TQDomNode &node) |
| virtual bool | readAttributesFromMathMLDom (const TQDomElement &element) |
| Protected Member Functions inherited from BasicElement | |
| virtual void | writeMathMLContent (TQDomDocument &, TQDomElement &, bool) const |
| bool | buildChild (SequenceElement *child, TQDomNode node, TQString name) |
| virtual int | readContentFromMathMLDom (TQDomNode &node) |
| virtual TQString | formulaString () |
| double | getSize (const TQString &str, SizeType *st) |
| SizeType | getSpace (const TQString &str) |
Additional Inherited Members | |
| Static Public Member Functions inherited from BasicElement | |
| static int | getEvilDestructionCount () |
Detailed Description
A element that represents a space.
Definition at line 38 of file spaceelement.h.
Constructor & Destructor Documentation
◆ SpaceElement() [1/2]
| KFORMULA_NAMESPACE_BEGIN SpaceElement::SpaceElement | ( | SpaceWidth | space = THIN, |
| bool | tab = false, | ||
| BasicElement * | parent = 0 ) |
Definition at line 36 of file spaceelement.cpp.
◆ SpaceElement() [2/2]
| SpaceElement::SpaceElement | ( | const SpaceElement & | other | ) |
Definition at line 65 of file spaceelement.cpp.
Member Function Documentation
◆ accept()
|
virtual |
Visit this element.
An implementation of the visitor pattern.
Implements BasicElement.
Definition at line 78 of file spaceelement.cpp.
◆ calcSizes()
|
virtual |
Calculates our width and height and our children's parentPosition.
Implements BasicElement.
Definition at line 84 of file spaceelement.cpp.
◆ clone()
|
inlinevirtual |
Implements BasicElement.
Definition at line 54 of file spaceelement.h.
◆ getCharacter()
|
inlinevirtual |
- Returns
- the type of this element. Used for parsing a sequence.
- the character that represents this element. Used for parsing a sequence.
Reimplemented from BasicElement.
Definition at line 70 of file spaceelement.h.
◆ getTagName()
|
inlineprotectedvirtual |
- Returns
- the tag name of this element type.
Reimplemented from BasicElement.
Definition at line 119 of file spaceelement.h.
◆ readAttributesFromDom()
|
protectedvirtual |
Reads our attributes from the element.
Returns false if it failed.
Reimplemented from BasicElement.
Definition at line 206 of file spaceelement.cpp.
◆ readAttributesFromMathMLDom()
|
protectedvirtual |
Reads our attributes from the MathML element.
Returns false if it failed.
Reimplemented from BasicElement.
Definition at line 242 of file spaceelement.cpp.
◆ readContentFromDom()
|
protectedvirtual |
Reads our content from the node.
Sets the node to the next node that needs to be read. Returns false if it failed.
Reimplemented from BasicElement.
Definition at line 237 of file spaceelement.cpp.
◆ toLatex()
|
virtual |
Draws the whole element including its children.
The `parentOrigin' is the point this element's parent starts. We can use our parentPosition to get our own origin then. */ virtual void draw( TQPainter& painter, const LuPixelRect& r, const ContextStyle& context, ContextStyle::TextStyle tstyle, ContextStyle::IndexStyle istyle, StyleAttributes& style, const LuPixelPoint& parentOrigin );
/** Moves the cursor away from the given child. The cursor is guaranteed to be inside this element.
- Returns
- the latex representation of the element and of the element's children
Reimplemented from BasicElement.
Definition at line 394 of file spaceelement.cpp.
◆ writeDom()
|
protectedvirtual |
Appends our attributes to the dom element.
Reimplemented from BasicElement.
Definition at line 161 of file spaceelement.cpp.
The documentation for this class was generated from the following files:
