]> Shamusworld >> Repos - architektonas/blob - src/base/rs_staticgraphicview.cpp
Removed more QC_ madness...
[architektonas] / src / base / rs_staticgraphicview.cpp
1 // rs_staticgraphicview.cpp
2 //
3 // Part of the Architektonas Project
4 // Originally part of QCad Community Edition by Andrew Mustun
5 // Extensively rewritten and refactored by James L. Hammons
6 // (C) 2010 Underground Software
7 //
8 // JLH = James L. Hammons <jlhamm@acm.org>
9 //
10 // Who  When        What
11 // ---  ----------  -----------------------------------------------------------
12 // JLH  06/02/2010  Added this text. :-)
13 // JLH  06/15/2010  Moved implementation (however trivial) from header to here.
14 //
15
16 #include "rs_staticgraphicview.h"
17
18 /**
19  * Constructor.
20  *
21  * @param w Width
22  * @param h Height
23  */
24 RS_StaticGraphicView::RS_StaticGraphicView(int w, int h, PaintInterface * p): /*painter(p),*/ width(w), height(h)
25 {
26         setBackground(RS_Color(255, 255, 255));
27         painter = p;
28         setBorders(5, 5, 5, 5);
29 }
30
31 /**
32  * Destructor
33  */
34 RS_StaticGraphicView::~RS_StaticGraphicView()
35 {
36 }
37
38 /**
39  * @return width of widget.
40  */
41 int RS_StaticGraphicView::getWidth()
42 {
43         return width;
44 }
45
46 /**
47  * @return height of widget.
48  */
49 int RS_StaticGraphicView::getHeight()
50 {
51         return height;
52 }
53
54 /**
55  * Handles paint events by redrawing the graphic in this view.
56  */
57 void RS_StaticGraphicView::paint()
58 {
59         RS_DEBUG->print("RS_StaticGraphicView::paint begin");
60         drawIt();
61         RS_DEBUG->print("RS_StaticGraphicView::paint end");
62 }
63
64 /*virtual*/ void RS_StaticGraphicView::redraw()
65 {
66 }
67
68 /*virtual*/ void RS_StaticGraphicView::adjustOffsetControls()
69 {
70 }
71
72 /*virtual*/ void RS_StaticGraphicView::adjustZoomControls()
73 {
74 }
75
76 /*virtual*/ void RS_StaticGraphicView::setMouseCursor(RS2::CursorType)
77 {
78 }
79
80 /*virtual*/ void RS_StaticGraphicView::emulateMouseMoveEvent()
81 {
82 }
83
84 /*virtual*/ void RS_StaticGraphicView::updateGridStatusWidget(const QString &)
85 {
86 }