kformula/flake

MultiscriptElement Class Reference

Implementation of the mmultiscript element. More...

#include <MultiscriptElement.h>

Inheritance diagram for MultiscriptElement:

List of all members.

Public Member Functions

 MultiscriptElement (BasicElement *parent=0)
 ~MultiscriptElement ()
virtual bool acceptCursor (const FormulaCursor &cursor)
QString attributesDefaultValue (const QString &attribute) const
const QList< BasicElement * > childElements () const
ElementType elementType () const
void layout (const AttributeManager *am)
virtual bool moveCursor (FormulaCursor &newcursor, FormulaCursor &oldcursor)
void paint (QPainter &painter, AttributeManager *am)
virtual bool setCursorTo (FormulaCursor &cursor, QPointF point)

Protected Member Functions

void ensureEvenNumberElements ()
bool readMathMLContent (const KoXmlElement &element)
void writeMathMLContent (KoXmlWriter *writer) const

Detailed Description

Implementation of the mmultiscript element.

Definition at line 30 of file MultiscriptElement.h.


Constructor & Destructor Documentation

MultiscriptElement::MultiscriptElement ( BasicElement parent = 0  ) 

The standard constructor.

Definition at line 29 of file MultiscriptElement.cpp.

MultiscriptElement::~MultiscriptElement (  ) 

The destructor.

Definition at line 34 of file MultiscriptElement.cpp.


Member Function Documentation

bool MultiscriptElement::acceptCursor ( const FormulaCursor cursor  )  [virtual]

Implement the cursor behaviour for the element.

Parameters:
cursor The FormulaCursor that is moved around
Returns:
A this pointer if the element accepts if not the element to asked instead

Reimplemented from FixedElement.

Definition at line 211 of file MultiscriptElement.cpp.

QString MultiscriptElement::attributesDefaultValue ( const QString attribute  )  const [virtual]
Returns:
The default value of the attribute for this element

Reimplemented from BasicElement.

Definition at line 234 of file MultiscriptElement.cpp.

const QList< BasicElement * > MultiscriptElement::childElements (  )  const [virtual]

Obtain a list of all child elements of this element.

Returns:
a QList with pointers to all child elements

Reimplemented from BasicElement.

Definition at line 217 of file MultiscriptElement.cpp.

ElementType MultiscriptElement::elementType (  )  const [virtual]
Returns:
The element's ElementType

Reimplemented from BasicElement.

Definition at line 240 of file MultiscriptElement.cpp.

void MultiscriptElement::ensureEvenNumberElements (  )  [protected]

Make sure that there are an even number of elements, as the spec says there must be.

Definition at line 51 of file MultiscriptElement.cpp.

void MultiscriptElement::layout ( const AttributeManager am  )  [virtual]

Calculate the size of the element and the positions of its children.

Parameters:
am The AttributeManager providing information about attributes values

Reimplemented from BasicElement.

Definition at line 62 of file MultiscriptElement.cpp.

bool MultiscriptElement::moveCursor ( FormulaCursor newcursor,
FormulaCursor oldcursor 
) [virtual]

Move the cursor in the direction specified in cursor.

Parameters:
newcursor the cursor we move around
oldcursor the former cursor position
Returns:
true, if we moved the cursor

Reimplemented from BasicElement.

Definition at line 324 of file MultiscriptElement.cpp.

void MultiscriptElement::paint ( QPainter painter,
AttributeManager am 
) [virtual]

Render the element to the given QPainter.

Parameters:
painter The QPainter to paint the element to
am AttributeManager containing style info

Reimplemented from BasicElement.

Definition at line 44 of file MultiscriptElement.cpp.

bool MultiscriptElement::readMathMLContent ( const KoXmlElement &  element  )  [protected, virtual]

Read all content from the node.

Reimplemented from BasicElement.

Definition at line 245 of file MultiscriptElement.cpp.

bool MultiscriptElement::setCursorTo ( FormulaCursor cursor,
QPointF  point 
) [virtual]

place the cursor at the the given point the point should be placed a the position in the element (or it's child) that is closest to the point in particular the point doesn't have to be within boundingBox()

Parameters:
cursor The FormulaCursor to modify
point The point in coordinates relative to the elements local coordinate system
Returns:
true, iff the cursor could be placed

Reimplemented from BasicElement.

Definition at line 498 of file MultiscriptElement.cpp.

void MultiscriptElement::writeMathMLContent ( KoXmlWriter *  writer  )  const [protected, virtual]

Write all content to the KoXmlWriter.

Reimplemented from BasicElement.

Definition at line 287 of file MultiscriptElement.cpp.


The documentation for this class was generated from the following files: