QCAD
Open Source 2D CAD
RTabletEvent.h
Go to the documentation of this file.
1 
20 #ifndef RTABLETEVENT_H
21 #define RTABLETEVENT_H
22 
23 #include "core_global.h"
24 
25 #include <QTabletEvent>
26 
27 #include "RVector.h"
28 
29 class RGraphicsScene;
30 class RGraphicsView;
31 
32 
33 
43 class QCADCORE_EXPORT RTabletEvent: public QTabletEvent {
44 public:
45  /*
46  RTabletEvent(
47  QEvent::Type type,
48  const RVector& position,
49  int device,
50  int pointerType,
51  qreal pressure,
52  int xTilt,
53  int yTilt,
54  qreal tangentialPressure,
55  qreal rotation,
56  int z,
57  Qt::KeyboardModifiers keyState,
58  qint64 uniqueID,
59  RGraphicsScene& s,
60  RGraphicsView& v);
61  */
62 
64  const QTabletEvent& tabletEvent,
65  RGraphicsScene& s,
66  RGraphicsView& v
67  );
68 
69  virtual ~RTabletEvent();
70 
71  RVector getModelPosition() const;
72  RVector getUcsPosition() const;
73  RVector getScreenPosition() const;
74 
76  RGraphicsScene& getGraphicsScene() const;
77 
78 protected:
82 
85 };
86 
88 
89 #endif
RVector
Represents a 3d vector (x/y/z).
Definition: RVector.h:46
RTabletEvent
A tablet event for a graphics scene.
Definition: RTabletEvent.h:43
RGraphicsView
Graphics view.
Definition: RGraphicsView.h:58
RVector.h
Q_DECLARE_METATYPE
Q_DECLARE_METATYPE(RMath *)
RTabletEvent::ucsPosition
RVector ucsPosition
Definition: RTabletEvent.h:80
RTabletEvent::view
RGraphicsView & view
Definition: RTabletEvent.h:84
getGraphicsView
void getGraphicsView()
Returns the current or last active RGraphicsView.
Definition: simple.js:93
core_global.h
RTabletEvent::scene
RGraphicsScene & scene
Definition: RTabletEvent.h:83
RGraphicsScene
Abstract base class for all graphics scenes.
Definition: RGraphicsScene.h:61
RTabletEvent::modelPosition
RVector modelPosition
Definition: RTabletEvent.h:79
RTabletEvent::screenPosition
RVector screenPosition
Definition: RTabletEvent.h:81
QCADCORE_EXPORT
#define QCADCORE_EXPORT
Definition: core_global.h:10