summaryrefslogtreecommitdiffstats
path: root/kpresenter/KPrObject.h
diff options
context:
space:
mode:
Diffstat (limited to 'kpresenter/KPrObject.h')
-rw-r--r--kpresenter/KPrObject.h148
1 files changed, 74 insertions, 74 deletions
diff --git a/kpresenter/KPrObject.h b/kpresenter/KPrObject.h
index bc532f5a..ce5b37c5 100644
--- a/kpresenter/KPrObject.h
+++ b/kpresenter/KPrObject.h
@@ -22,8 +22,8 @@
#ifndef kpobject_h
#define kpobject_h
-#include <qbrush.h>
-#include <qcursor.h>
+#include <tqbrush.h>
+#include <tqcursor.h>
#include "global.h"
@@ -42,11 +42,11 @@
#include <KoPen.h>
class KoSavingContext;
-class QPainter;
+class TQPainter;
class DCOPObject;
-class QDomDocumentFragment;
-class QDomDocument;
-class QDomElement;
+class TQDomDocumentFragment;
+class TQDomDocument;
+class TQDomElement;
class KoTextZoomHandler;
class KPrDocument;
class KPrTextObject;
@@ -72,7 +72,7 @@ public:
virtual void setSize( const KoSize & _size )
{ setSize( _size.width(), _size.height() ); }
virtual void setSize(double _width, double _height )
- { ext = KoSize( QMAX( MIN_SIZE, _width ), QMAX( MIN_SIZE, _height ) ); } // no object is smaller than 10x10
+ { ext = KoSize( TQMAX( MIN_SIZE, _width ), TQMAX( MIN_SIZE, _height ) ); } // no object is smaller than 10x10
virtual void setOrig( const KoPoint & _point )
{ orig = _point; }
virtual void setOrig( double _x, double _y )
@@ -86,7 +86,7 @@ public:
virtual void resizeBy( double _dx, double _dy )
{ setSize( ext.width() + _dx, ext.height() + _dy ); } // call (possibly reimplemented) setSize
- virtual void setShadowParameter(int _distance,ShadowDirection _direction,const QColor &_color)
+ virtual void setShadowParameter(int _distance,ShadowDirection _direction,const TQColor &_color)
{
shadowDistance = _distance;
shadowDirection = _direction;
@@ -97,7 +97,7 @@ public:
{ shadowDistance = _distance; }
virtual void setShadowDirection( ShadowDirection _direction )
{ shadowDirection = _direction; }
- virtual void setShadowColor( const QColor & _color )
+ virtual void setShadowColor( const TQColor & _color )
{ shadowColor = _color; }
virtual void setEffect( Effect _effect )
{ effect = _effect; }
@@ -123,19 +123,19 @@ public:
{ appearSoundEffect = b; }
virtual void setDisappearSoundEffect( bool b )
{ disappearSoundEffect = b; }
- virtual void setAppearSoundEffectFileName( const QString & _a_fileName )
+ virtual void setAppearSoundEffectFileName( const TQString & _a_fileName )
{ a_fileName = _a_fileName; }
- virtual void setDisappearSoundEffectFileName( const QString &_d_fileName )
+ virtual void setDisappearSoundEffectFileName( const TQString &_d_fileName )
{ d_fileName = _d_fileName; }
- virtual void setObjectName( const QString &_objectName )
+ virtual void setObjectName( const TQString &_objectName )
{ objectName = _objectName; }
- virtual QString getObjectName() const
+ virtual TQString getObjectName() const
{ return objectName; }
- virtual QDomDocumentFragment save( QDomDocument& doc, double offset );
- virtual double load(const QDomElement &element);
- virtual void loadOasis(const QDomElement &element, KoOasisContext & context, KPrLoadingInfo *info);
+ virtual TQDomDocumentFragment save( TQDomDocument& doc, double offset );
+ virtual double load(const TQDomElement &element);
+ virtual void loadOasis(const TQDomElement &element, KoOasisContext & context, KPrLoadingInfo *info);
struct KPOasisSaveContext
{
@@ -164,8 +164,8 @@ public:
virtual ObjType getType() const
{ return OT_UNDEFINED; }
- virtual QString getTypeString() const
- { return QString(); }
+ virtual TQString getTypeString() const
+ { return TQString(); }
virtual bool isSelected() const
{ return selected; }
@@ -175,7 +175,7 @@ public:
{ return shadowDistance; }
virtual ShadowDirection getShadowDirection() const
{ return shadowDirection; }
- virtual QColor getShadowColor() const
+ virtual TQColor getShadowColor() const
{ return shadowColor; }
virtual KoSize getSize() const
{ return ext; }
@@ -188,7 +188,7 @@ public:
virtual KoPoint getRealOrig() const;
KoRect getRealRect() const;
/**
- * @brief Get the rect which has to be repainted
+ * @brief Get the rect which has to be tqrepainted
*
* This also contains the shadow.
*/
@@ -212,9 +212,9 @@ public:
{ return appearSoundEffect; }
virtual bool getDisappearSoundEffect() const
{ return disappearSoundEffect; }
- virtual QString getAppearSoundEffectFileName() const
+ virtual TQString getAppearSoundEffectFileName() const
{ return a_fileName; }
- virtual QString getDisappearSoundEffectFileName() const
+ virtual TQString getDisappearSoundEffectFileName() const
{ return d_fileName; }
/**
* get the step when the object appears on the site
@@ -239,7 +239,7 @@ public:
{ specEffects = _specEffects; onlyCurrStep = _onlyCurrStep; }
// the main drawing method.
- virtual void draw( QPainter *_painter, KoTextZoomHandler*_zoomHandler,
+ virtual void draw( TQPainter *_painter, KoTextZoomHandler*_zoomHandler,
int /*pageNum*/, SelectionMode selectionMode, bool drawContour = FALSE );
/**
@@ -250,7 +250,7 @@ public:
* @return true if point lies in rect of object
* @return false otherwise
*/
- virtual bool contains( const KoPoint &point ) const;
+ virtual bool tqcontains( const KoPoint &point ) const;
/**
* @brief Check if rect intersects with rect of object
@@ -262,10 +262,10 @@ public:
*/
virtual bool intersects( const KoRect & rect ) const;
- virtual QCursor getCursor( const KoPoint &_point, ModifyType &_modType, KPrDocument *doc ) const;
+ virtual TQCursor getCursor( const KoPoint &_point, ModifyType &_modType, KPrDocument *doc ) const;
KoRect rotateRectObject() const;
- void rotateObject(QPainter *paint,KoTextZoomHandler *_zoomHandler);
+ void rotateObject(TQPainter *paint,KoTextZoomHandler *_zoomHandler);
virtual void removeFromObjList()
{ inObjList = false; }
@@ -282,20 +282,20 @@ public:
virtual void setKeepRatio( bool b ) { keepRatio = b; }
bool isKeepRatio() const { return keepRatio; }
- static void setupClipRegion( QPainter *painter, const QRegion &clipRegion );
+ static void setupClipRegion( TQPainter *painter, const TQRegion &clipRegion );
- void paintSelection( QPainter *_painter,KoTextZoomHandler *_zoomHandler,
+ void paintSelection( TQPainter *_painter,KoTextZoomHandler *_zoomHandler,
SelectionMode selectionMode );
/**
* Collect all textobjects.
- * (KPrTextObject returns the object it contains,
- * a KPrGroupObject returns all the text objects it contains)
+ * (KPrTextObject returns the object it tqcontains,
+ * a KPrGroupObject returns all the text objects it tqcontains)
*/
- virtual void addTextObjects( QPtrList<KoTextObject> & ) const {}
+ virtual void addTextObjects( TQPtrList<KoTextObject> & ) const {}
virtual KPrTextObject *nextTextObject() { return 0L;} // deprecated
- virtual void getAllObjectSelectedList(QPtrList<KPrObject> &lst, bool force = false )
+ virtual void getAllObjectSelectedList(TQPtrList<KPrObject> &lst, bool force = false )
{ if (selected || force ) lst.append( this );}
virtual KoPen getPen() const;
@@ -304,7 +304,7 @@ public:
/**
* Adds its edges to the KoGuides objectCollect all textobjects.
*/
- void addSelfToGuides( QValueList<double> &horizontalPos, QValueList<double> &verticalPos );
+ void addSelfToGuides( TQValueList<double> &horizontalPos, TQValueList<double> &verticalPos );
protected:
/**
@@ -323,23 +323,23 @@ protected:
virtual void doDelete();
- QDomElement createValueElement(const QString &tag, int value, QDomDocument &doc);
- QDomElement createGradientElement(const QString &tag, const QColor &c1, const QColor &c2,
- int type, bool unbalanced, int xfactor, int yfactor, QDomDocument &doc);
- QDomElement createPenElement(const QString &tag, const KoPen &pen, QDomDocument &doc);
- KoPen toPen(const QDomElement &element) const;
+ TQDomElement createValueElement(const TQString &tag, int value, TQDomDocument &doc);
+ TQDomElement createGradientElement(const TQString &tag, const TQColor &c1, const TQColor &c2,
+ int type, bool unbalanced, int xfactor, int yfactor, TQDomDocument &doc);
+ TQDomElement createPenElement(const TQString &tag, const KoPen &pen, TQDomDocument &doc);
+ KoPen toPen(const TQDomElement &element) const;
- QDomElement createBrushElement(const QString &tag, const QBrush &brush, QDomDocument &doc);
- QBrush toBrush(const QDomElement &element) const;
+ TQDomElement createBrushElement(const TQString &tag, const TQBrush &brush, TQDomDocument &doc);
+ TQBrush toBrush(const TQDomElement &element) const;
- QColor retrieveColor(const QDomElement &element, const QString &cattr="color",
- const QString &rattr="red", const QString &gattr="green",
- const QString &battr="blue") const;
+ TQColor retrieveColor(const TQDomElement &element, const TQString &cattr="color",
+ const TQString &rattr="red", const TQString &gattr="green",
+ const TQString &battr="blue") const;
void saveOasisObjectProtectStyle( KoGenStyle &styleobjectauto ) const;
void saveOasisShadowElement( KoGenStyle &styleobjectauto ) const;
- QString getStyle( KPOasisSaveContext &sc ) const;
+ TQString getStyle( KPOasisSaveContext &sc ) const;
virtual void fillStyle( KoGenStyle& styleObjectAuto, KoGenStyles& mainStyles ) const;
/**
* Get the element name for saving the object
@@ -354,15 +354,15 @@ protected:
KoSize ext;
int shadowDistance;
ShadowDirection shadowDirection;
- QColor shadowColor;
+ TQColor shadowColor;
Effect effect;
Effect2 effect2;
Effect3 effect3;
EffectSpeed m_appearSpeed;
EffectSpeed m_disappearSpeed;
int appearTimer, disappearTimer;
- QString a_fileName, d_fileName;
- QString objectName;
+ TQString a_fileName, d_fileName;
+ TQString objectName;
// step when objects appears/disappears
int appearStep, disappearStep;
@@ -383,7 +383,7 @@ protected:
DCOPObject *dcop;
- static const QString &tagORIG, &attrX, &attrY,
+ static const TQString &tagORIG, &attrX, &attrY,
&tagSIZE, &attrWidth, &attrHeight, &tagSHADOW,
&attrDistance, &attrDirection, &attrColor, &attrC1,
&attrC2, &attrType, &attrUnbalanced, &attrXFactor,
@@ -417,13 +417,13 @@ public:
virtual KoPen getPen() const
{ return pen; }
- virtual QDomDocumentFragment save( QDomDocument& doc, double offset );
- virtual double load(const QDomElement &element);
- virtual void loadOasis(const QDomElement &element, KoOasisContext & context, KPrLoadingInfo *info);
- virtual void draw( QPainter *_painter, KoTextZoomHandler*_zoomHandler,
+ virtual TQDomDocumentFragment save( TQDomDocument& doc, double offset );
+ virtual double load(const TQDomElement &element);
+ virtual void loadOasis(const TQDomElement &element, KoOasisContext & context, KPrLoadingInfo *info);
+ virtual void draw( TQPainter *_painter, KoTextZoomHandler*_zoomHandler,
int pageNum, SelectionMode selectionMode, bool drawContour = FALSE );
virtual void saveOasisStrokeElement( KoGenStyles& mainStyles, KoGenStyle &styleobjectauto ) const;
- QString saveOasisStrokeStyle( KoGenStyles& mainStyles ) const;
+ TQString saveOasisStrokeStyle( KoGenStyles& mainStyles ) const;
protected:
/**
@@ -434,7 +434,7 @@ protected:
/**
* Helper method for loading draw:points. The svg:viewBox is taken into account.
*/
- bool loadOasisDrawPoints( KoPointArray &points, const QDomElement &element,
+ bool loadOasisDrawPoints( KoPointArray &points, const TQDomElement &element,
KoOasisContext & context, KPrLoadingInfo *info );
@@ -449,7 +449,7 @@ protected:
* @param element the xml element from which the viewBox attribute should be read.
* @param points which should be updated.
*/
- bool loadOasisApplyViewBox( const QDomElement &element, KoPointArray &points );
+ bool loadOasisApplyViewBox( const TQDomElement &element, KoPointArray &points );
virtual void fillStyle( KoGenStyle& styleObjectAuto, KoGenStyles& mainStyles ) const;
@@ -471,7 +471,7 @@ protected:
*
* This method isn't pure virtual because some objects implement draw() directly.
*/
- virtual void paint( QPainter* /* painter */, KoTextZoomHandler* /* zoomHandler */,
+ virtual void paint( TQPainter* /* painter */, KoTextZoomHandler* /* zoomHandler */,
int /* pageNum */, bool drawingShadow, bool /* drawContour */ = FALSE );
KoPen pen;
};
@@ -480,17 +480,17 @@ class KPr2DObject : public KPrShadowObject
{
public:
KPr2DObject();
- KPr2DObject( const KoPen &_pen, const QBrush &_brush, FillType _fillType,
- const QColor &_gColor1, const QColor &_gColor2, BCType _gType,
+ KPr2DObject( const KoPen &_pen, const TQBrush &_brush, FillType _fillType,
+ const TQColor &_gColor1, const TQColor &_gColor2, BCType _gType,
bool _unbalanced, int _xfactor, int _yfactor );
virtual ~KPr2DObject() { delete gradient; }
virtual void setFillType( FillType fillType );
- virtual void setBrush( const QBrush &brush )
+ virtual void setBrush( const TQBrush &brush )
{ m_brush.setBrush( brush ); }
- virtual void setGColor1( const QColor &gColor1 )
+ virtual void setGColor1( const TQColor &gColor1 )
{ if ( gradient ) gradient->setColor1( gColor1 ); m_brush.setGColor1( gColor1 ); m_redrawGradientPix = true; }
- virtual void setGColor2( const QColor &gColor2 )
+ virtual void setGColor2( const TQColor &gColor2 )
{ if ( gradient ) gradient->setColor2( gColor2 ); m_brush.setGColor2( gColor2 ); m_redrawGradientPix = true; }
virtual void setGType( BCType gType )
{ if ( gradient ) gradient->setBackColorType( gType ); m_brush.setGType( gType ); m_redrawGradientPix = true; }
@@ -503,11 +503,11 @@ public:
virtual FillType getFillType() const
{ return m_brush.getFillType(); }
- virtual QBrush getBrush() const
+ virtual TQBrush getBrush() const
{ return m_brush.getBrush(); }
- virtual QColor getGColor1() const
+ virtual TQColor getGColor1() const
{ return m_brush.getGColor1(); }
- virtual QColor getGColor2() const
+ virtual TQColor getGColor2() const
{ return m_brush.getGColor2(); }
virtual BCType getGType() const
{ return m_brush.getGType(); }
@@ -518,10 +518,10 @@ public:
virtual int getGYFactor() const
{ return m_brush.getGYFactor(); }
- virtual QDomDocumentFragment save( QDomDocument& doc, double offset );
- virtual double load(const QDomElement &element);
- virtual void loadOasis(const QDomElement &element, KoOasisContext & context, KPrLoadingInfo *info);
- virtual void draw( QPainter *_painter, KoTextZoomHandler*_zoomHandler,
+ virtual TQDomDocumentFragment save( TQDomDocument& doc, double offset );
+ virtual double load(const TQDomElement &element);
+ virtual void loadOasis(const TQDomElement &element, KoOasisContext & context, KPrLoadingInfo *info);
+ virtual void draw( TQPainter *_painter, KoTextZoomHandler*_zoomHandler,
int pageNum, SelectionMode selectionMode, bool drawContour = FALSE );
virtual void flip(bool horizontal );
@@ -532,7 +532,7 @@ protected:
KPrBrush m_brush;
KPrGradient *gradient;
/// holds the painted gradient
- QPixmap m_gradientPix;
+ TQPixmap m_gradientPix;
bool m_redrawGradientPix;
};
@@ -540,16 +540,16 @@ class KPrStartEndLine
{
public:
KPrStartEndLine( LineEnd _start, LineEnd _end );
- void save( QDomDocumentFragment &fragment, QDomDocument& doc );
- void load( const QDomElement &element );
+ void save( TQDomDocumentFragment &fragment, TQDomDocument& doc );
+ void load( const TQDomElement &element );
void saveOasisMarkerElement( KoGenStyles& mainStyles, KoGenStyle &styleobjectauto ) const;
- QString saveOasisMarkerStyle( KoGenStyles &mainStyles, const LineEnd &_element ) const;
- void loadOasisMarkerElement( KoOasisContext & context, const QString & attr, LineEnd &_element );
+ TQString saveOasisMarkerStyle( KoGenStyles &mainStyles, const LineEnd &_element ) const;
+ void loadOasisMarkerElement( KoOasisContext & context, const TQString & attr, LineEnd &_element );
protected:
//duplicate from kpobject
- QDomElement createValueElement(const QString &tag, int value, QDomDocument &doc);
+ TQDomElement createValueElement(const TQString &tag, int value, TQDomDocument &doc);
LineEnd lineBegin, lineEnd;
};