22#include "bracketelement.h"
23#include "creationstrategy.h"
24#include "elementtype.h"
25#include "fractionelement.h"
26#include "identifierelement.h"
27#include "indexelement.h"
28#include "matrixelement.h"
29#include "operatorelement.h"
30#include "rootelement.h"
31#include "sequenceelement.h"
32#include "spaceelement.h"
33#include "symbolelement.h"
34#include "textelement.h"
35#include "numberelement.h"
37KFORMULA_NAMESPACE_BEGIN
39BasicElement* OrdinaryCreationStrategy::createElement( TQString type,
const TQDomElement& )
44 else if ( type ==
"ROOT" )
return new RootElement();
50 else if ( type ==
"NAMESEQUENCE" )
return new NameSequence();
54 else if ( type ==
"SEQUENCE" ) {
55 kdWarning() <<
"malformed data: sequence inside sequence." << endl;
67EmptyElement* OrdinaryCreationStrategy::createEmptyElement()
72NameSequence* OrdinaryCreationStrategy::createNameSequence()
77BracketElement* OrdinaryCreationStrategy::createBracketElement( SymbolType lhs, SymbolType rhs )
97SpaceElement* OrdinaryCreationStrategy::createSpaceElement( SpaceWidth width )
107RootElement* OrdinaryCreationStrategy::createRootElement()
112SymbolElement* OrdinaryCreationStrategy::createSymbolElement( SymbolType type )
122IndexElement* OrdinaryCreationStrategy::createIndexElement()
127IdentifierElement* OrdinaryCreationStrategy::createIdentifierElement()
129 return new IdentifierElement();
132OperatorElement* OrdinaryCreationStrategy::createOperatorElement()
134 return new OperatorElement();
137NumberElement* OrdinaryCreationStrategy::createNumberElement()
139 return new NumberElement();
144KFORMULA_NAMESPACE_END
Basis of every formula element.
A left and/or right bracket around one child.
An element that represents an empty box.
The element with up to four indexes in the four corners.
The sequence thats a name.
virtual MatrixElement * createMatrixElement(uint rows, uint columns)
when this gets called the user has seen the matrix dialog and expects a matrix!
virtual TextElement * createTextElement(const TQChar &ch, bool symbol=false)
there must always be a TextElement, so this can never return 0
A line above the content.
A element that represents a space.
A symbol is simply a piece of art.
An element that represents one char.
A line below the content.