QCAD Application Framework
CAD Application Development and Automation.
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
RRuler.h
Go to the documentation of this file.
1 #ifndef RRULER_H
2 #define RRULER_H
3 
4 #include <Qt>
5 #include <QMetaType>
6 
7 class QFont;
8 class RGraphicsView;
9 
16 class RRuler {
17 
18 public:
19  RRuler() :
20  view(NULL), orientation(Qt::Horizontal) {
21  }
22  virtual ~RRuler() {
23  }
24 
26  this->view = view;
27  }
28 
29  Qt::Orientation getOrientation() const {
30  return orientation;
31  }
32 
33  void setOrientation(Qt::Orientation orientation) {
34  this->orientation = orientation;
35  }
36 
37  virtual void paintTick(int pos, bool major, const QString& label) = 0;
38 
39  virtual QFont getFont() const = 0;
40 
41 protected:
43  Qt::Orientation orientation;
44 };
45 
47 
48 #endif