diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /lib/kformula/rootelement.h | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'lib/kformula/rootelement.h')
-rw-r--r-- | lib/kformula/rootelement.h | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/lib/kformula/rootelement.h b/lib/kformula/rootelement.h index 0d579fd8..b836228e 100644 --- a/lib/kformula/rootelement.h +++ b/lib/kformula/rootelement.h @@ -21,7 +21,7 @@ #ifndef ROOTELEMENT_H #define ROOTELEMENT_H -#include <qpoint.h> +#include <tqpoint.h> #include "basicelement.h" @@ -38,7 +38,7 @@ public: //enum { contentPos, indexPos }; - RootElement(BasicElement* parent = 0); + RootElement(BasicElement* tqparent = 0); ~RootElement(); RootElement( const RootElement& ); @@ -62,11 +62,11 @@ public: * is allowed to set the cursor. */ virtual BasicElement* goToPos( FormulaCursor*, bool& handled, - const LuPixelPoint& point, const LuPixelPoint& parentOrigin ); + const LuPixelPoint& point, const LuPixelPoint& tqparentOrigin ); /** * Calculates our width and height and - * our children's parentPosition. + * our tqchildren's tqparentPosition. */ virtual void calcSizes( const ContextStyle& cstyle, ContextStyle::TextStyle tstyle, @@ -74,19 +74,19 @@ public: StyleAttributes& style ); /** - * 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. + * Draws the whole element including its tqchildren. + * The `tqparentOrigin' is the point this element's tqparent starts. + * We can use our tqparentPosition to get our own origin then. */ - virtual void draw( QPainter& painter, const LuPixelRect& r, + virtual void draw( TQPainter& painter, const LuPixelRect& r, const ContextStyle& cstyle, ContextStyle::TextStyle tstyle, ContextStyle::IndexStyle istyle, StyleAttributes& style, - const LuPixelPoint& parentOrigin ); + const LuPixelPoint& tqparentOrigin ); /** - * Dispatch this FontCommand to all our TextElement children. + * Dispatch this FontCommand to all our TextElement tqchildren. */ virtual void dispatchFontCommand( FontCommand* cmd ); @@ -121,15 +121,15 @@ public: /** * Reinserts the index if it has been removed. */ - virtual void insert(FormulaCursor*, QPtrList<BasicElement>&, Direction); + virtual void insert(FormulaCursor*, TQPtrList<BasicElement>&, Direction); /** - * Removes all selected children and returns them. Places the - * cursor to where the children have been. + * Removes all selected tqchildren and returns them. Places the + * cursor to where the tqchildren have been. * * We remove ourselve if we are requested to remove our content. */ - virtual void remove(FormulaCursor*, QPtrList<BasicElement>&, Direction); + virtual void remove(FormulaCursor*, TQPtrList<BasicElement>&, Direction); /** * Moves the cursor to a normal place where new elements @@ -139,7 +139,7 @@ public: // main child // - // If an element has children one has to become the main one. + // If an element has tqchildren one has to become the main one. virtual SequenceElement* getMainChild(); SequenceElement* getRadiant() { return index; } @@ -170,16 +170,16 @@ public: ElementIndexPtr getIndex() { return ElementIndexPtr( new RootElementIndex( this ) ); } // Save&load - //virtual QDomElement getElementDom(QDomDocument *doc); - //virtual bool buildFromDom(QDomElement *elem); + //virtual TQDomElement getElementDom(TQDomDocument *doc); + //virtual bool buildFromDom(TQDomElement *elem); /** * @returns the latex representation of the element and - * of the element's children + * of the element's tqchildren */ - virtual QString toLatex(); + virtual TQString toLatex(); - virtual QString formulaString(); + virtual TQString formulaString(); protected: @@ -188,59 +188,59 @@ protected: /** * Returns the tag name of this element type. */ - virtual QString getTagName() const { return "ROOT"; } + virtual TQString getTagName() const { return "ROOT"; } /** * Appends our attributes to the dom element. */ - virtual void writeDom(QDomElement element); + virtual void writeDom(TQDomElement element); /** * Reads our attributes from the element. * Returns false if it failed. */ - virtual bool readAttributesFromDom(QDomElement element); + virtual bool readAttributesFromDom(TQDomElement element); /** * Reads our content from the node. Sets the node to the next node * that needs to be read. * Returns false if it failed. */ - virtual bool readContentFromDom(QDomNode& node); + virtual bool readContentFromDom(TQDomNode& node); /** * Reads our attributes from the MathML element. * Also checks whether it's a msqrt or mroot. * Returns false if it failed. */ - virtual bool readAttributesFromMathMLDom(const QDomElement& element); + virtual bool readAttributesFromMathMLDom(const TQDomElement& element); /** * Reads our content from the MathML node. Sets the node to the next node * that needs to be read. * Returns false if it failed. */ - virtual int readContentFromMathMLDom(QDomNode& node); + virtual int readContentFromMathMLDom(TQDomNode& node); private: - virtual QString getElementName() const { return hasIndex() ? "mroot" : "msqrt"; } - virtual void writeMathMLContent( QDomDocument& doc, - QDomElement& element, + virtual TQString getElementName() const { return hasIndex() ? "mroot" : "msqrt"; } + virtual void writeMathMLContent( TQDomDocument& doc, + TQDomElement& element, bool oasisFormat ) const ; class RootElementIndex : public ElementIndex { public: - RootElementIndex(RootElement* p) : parent(p) {} + RootElementIndex(RootElement* p) : tqparent(p) {} virtual void moveToIndex(FormulaCursor* cursor, Direction direction) - { parent->moveToIndex(cursor, direction); } + { tqparent->moveToIndex(cursor, direction); } virtual void setToIndex(FormulaCursor* cursor) - { parent->setToIndex(cursor); } + { tqparent->setToIndex(cursor); } virtual bool hasIndex() const - { return parent->hasIndex(); } - virtual RootElement* getElement() { return parent; } + { return tqparent->hasIndex(); } + virtual RootElement* getElement() { return tqparent; } protected: - RootElement* parent; + RootElement* tqparent; }; |