Diffstat (limited to 'noncore/multimedia/tonleiter/fretboard.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/multimedia/tonleiter/fretboard.h | 80 |
1 files changed, 41 insertions, 39 deletions
diff --git a/noncore/multimedia/tonleiter/fretboard.h b/noncore/multimedia/tonleiter/fretboard.h index eb509b0..458c733 100644 --- a/noncore/multimedia/tonleiter/fretboard.h +++ b/noncore/multimedia/tonleiter/fretboard.h | |||
@@ -10,44 +10,46 @@ | |||
10 | #include "tonleiterdata.h" | 10 | #include "tonleiterdata.h" |
11 | 11 | ||
12 | class FretBoard : public QWidget | 12 | using namespace Data; |
13 | |||
14 | namespace Graph | ||
13 | { | 15 | { |
14 | Q_OBJECT | 16 | class FretBoard : public QWidget |
15 | private: | 17 | { |
16 | TonleiterData* data; | 18 | Q_OBJECT |
17 | 19 | private: | |
18 | QPen fretpen; | 20 | TonleiterData* data; |
19 | QBrush markerbrush; | 21 | |
20 | QPen stringpen; | 22 | QPen fretpen; |
21 | 23 | QBrush markerbrush; | |
22 | Instrument inst; | 24 | QPen stringpen; |
23 | 25 | ||
24 | int xmargin; | 26 | Instrument inst; |
25 | int xmin; | 27 | |
26 | int xmax; | 28 | int xmargin; |
27 | int xwidth; | 29 | int xmin; |
28 | 30 | int xmax; | |
29 | int ymargin; | 31 | int xwidth; |
30 | int ymin; | 32 | |
31 | int ymax; | 33 | int ymargin; |
32 | int yheight; | 34 | int ymin; |
33 | 35 | int ymax; | |
34 | double fretdist; | 36 | int yheight; |
35 | double stringdist; | 37 | |
36 | 38 | double fretdist; | |
37 | public: | 39 | double stringdist; |
38 | FretBoard(TonleiterData* data,QWidget* parent,const char* name="FretBoard",WFlags f=0); | 40 | |
39 | virtual ~FretBoard(); | 41 | public: |
40 | private slots: | 42 | FretBoard(TonleiterData* data,QWidget* parent,const char* name="FretBoard",WFlags f=0); |
41 | void dataChange(); | 43 | virtual ~FretBoard(); |
42 | private: | 44 | private slots: |
43 | void paintEvent(QPaintEvent* pe); | 45 | void dataChange(); |
44 | void resizeEvent(QResizeEvent* re); | 46 | private: |
45 | //void mousePressEvent(QMouseEvent* mpe); | 47 | void paintEvent(QPaintEvent* pe); |
46 | //void mouseMoveEvent(QMouseEvent* mme); | 48 | void resizeEvent(QResizeEvent* re); |
47 | //void mouseReleaseEvent(QMouseEvent* mre); | 49 | void paintBoard(QPainter* p); |
48 | void paintBoard(QPainter* p); | 50 | void paintFrets(QPainter* p); |
49 | void paintFrets(QPainter* p); | 51 | void paintStrings(QPainter* p); |
50 | void paintStrings(QPainter* p); | 52 | void paintScale(QPainter* p); |
51 | void paintScale(QPainter* p); | 53 | }; |
52 | }; | 54 | }; |
53 | 55 | ||