summaryrefslogtreecommitdiffstats
path: root/kugar/kudesigner_lib/view.h
diff options
context:
space:
mode:
Diffstat (limited to 'kugar/kudesigner_lib/view.h')
-rw-r--r--kugar/kudesigner_lib/view.h61
1 files changed, 31 insertions, 30 deletions
diff --git a/kugar/kudesigner_lib/view.h b/kugar/kudesigner_lib/view.h
index 8ca5a9d4..5b4ebe40 100644
--- a/kugar/kudesigner_lib/view.h
+++ b/kugar/kudesigner_lib/view.h
@@ -19,16 +19,16 @@
#ifndef VIEW_H
#define VIEW_H
-#include <qcanvas.h>
-#include <qpainter.h>
-#include <qptrlist.h>
+#include <tqcanvas.h>
+#include <tqpainter.h>
+#include <tqptrlist.h>
#include <koproperty/property.h>
class KuDesignerPlugin;
-class QMouseEvent;
-class QCanvasItemList;
+class TQMouseEvent;
+class TQCanvasItemList;
namespace KoProperty
{
@@ -45,21 +45,22 @@ class Box;
class Canvas;
class Band;
-class SelectionRect: public QCanvasRectangle
+class SelectionRect: public TQCanvasRectangle
{
public:
SelectionRect( int x, int y, int width, int height, Canvas *canvas ) :
- QCanvasRectangle( x, y, width, height, ( QCanvas* ) canvas )
+ TQCanvasRectangle( x, y, width, height, ( TQCanvas* ) canvas )
{}
- virtual void draw( QPainter & painter );
+ virtual void draw( TQPainter & painter );
};
-class View: public QCanvasView
+class View: public TQCanvasView
{
Q_OBJECT
+ TQ_OBJECT
public:
- View( Canvas *canvas, QWidget *parent, const char *name = 0, WFlags f = 0 );
+ View( Canvas *canvas, TQWidget *tqparent, const char *name = 0, WFlags f = 0 );
int itemToInsert;
@@ -76,23 +77,23 @@ public:
void setCanvas( Canvas *canvas );
protected:
- void contentsMousePressEvent( QMouseEvent* );
- void contentsMouseReleaseEvent( QMouseEvent* );
- void contentsMouseMoveEvent( QMouseEvent* );
- void contentsMouseDoubleClickEvent( QMouseEvent * );
-
- void contentsDragEnterEvent ( QDragEnterEvent * );
- void contentsDragMoveEvent ( QDragMoveEvent * );
- // void contentsDragLeaveEvent ( QDragLeaveEvent * );
- // void contentsDropEvent ( QDropEvent * );
- void keyPressEvent( QKeyEvent * );
-
- void startMoveOrResizeOrSelectItem( QCanvasItemList &l, QMouseEvent *e, QPoint &p );
- bool startResizing( QMouseEvent *e, QPoint &p );
- void placeItem( QCanvasItemList &l, QMouseEvent *e );
- void editItem( QCanvasItemList &l );
- void deleteItem( QCanvasItemList &l );
- void selectItemFromList( QCanvasItemList &l );
+ void contentsMousePressEvent( TQMouseEvent* );
+ void contentsMouseReleaseEvent( TQMouseEvent* );
+ void contentsMouseMoveEvent( TQMouseEvent* );
+ void contentsMouseDoubleClickEvent( TQMouseEvent * );
+
+ void contentsDragEnterEvent ( TQDragEnterEvent * );
+ void contentsDragMoveEvent ( TQDragMoveEvent * );
+ // void contentsDragLeaveEvent ( TQDragLeaveEvent * );
+ // void contentsDropEvent ( TQDropEvent * );
+ void keyPressEvent( TQKeyEvent * );
+
+ void startMoveOrResizeOrSelectItem( TQCanvasItemList &l, TQMouseEvent *e, TQPoint &p );
+ bool startResizing( TQMouseEvent *e, TQPoint &p );
+ void placeItem( TQCanvasItemList &l, TQMouseEvent *e );
+ void editItem( TQCanvasItemList &l );
+ void deleteItem( TQCanvasItemList &l );
+ void selectItemFromList( TQCanvasItemList &l );
void stickToGrid( double &x, double &y );
void stickDimToGrid( double x, double y, double &X, double &Y );
@@ -101,11 +102,11 @@ private:
Buffer *selectionBuf;
ReportItem *moving;
- QPoint moving_start;
+ TQPoint moving_start;
double moving_offsetY;
double moving_offsetX;
- QRect resizing_constraint;
- QSize resizing_minSize;
+ TQRect resizing_constraint;
+ TQSize resizing_minSize;
int resizing_type;
class Box *resizing;
bool selectionStarted;