Line | |
---|
1 |
|
---|
2 | #ifndef POLARPLOT_H
|
---|
3 | #define POLARPLOT_H
|
---|
4 |
|
---|
5 | #include <qwt_polar_plot.h>
|
---|
6 | #include <qwt_polar_curve.h>
|
---|
7 | //
|
---|
8 | //////////////////////////////////////////////////////////////////////////////
|
---|
9 | class t_polarCurve : public QwtPolarCurve {
|
---|
10 | public:
|
---|
11 | t_polarCurve() {}
|
---|
12 | virtual ~t_polarCurve() {}
|
---|
13 | protected:
|
---|
14 | virtual void drawSymbols (QPainter* painter, const QwtSymbol& symbol,
|
---|
15 | const QwtScaleMap& azimuthMap,
|
---|
16 | const QwtScaleMap& radialMap,
|
---|
17 | const QPointF& pole, int from, int to) const;
|
---|
18 | };
|
---|
19 |
|
---|
20 | //
|
---|
21 | //////////////////////////////////////////////////////////////////////////////
|
---|
22 | class t_polarData: public QwtSeriesData<QwtPointPolar> {
|
---|
23 | public:
|
---|
24 | t_polarData(size_t size) {
|
---|
25 | _size = size;
|
---|
26 | }
|
---|
27 | virtual QwtPointPolar sample(size_t ii) const;
|
---|
28 | virtual size_t size() const {return _size;}
|
---|
29 | virtual QRectF boundingRect() const {
|
---|
30 | return d_boundingRect;
|
---|
31 | }
|
---|
32 | protected:
|
---|
33 | size_t _size;
|
---|
34 | };
|
---|
35 |
|
---|
36 | //
|
---|
37 | //////////////////////////////////////////////////////////////////////////////
|
---|
38 | class t_polarPlot: public QwtPolarPlot {
|
---|
39 | Q_OBJECT
|
---|
40 |
|
---|
41 | public:
|
---|
42 | t_polarPlot(QWidget* = 0);
|
---|
43 |
|
---|
44 | private:
|
---|
45 | t_polarCurve* createCurve() const;
|
---|
46 | };
|
---|
47 |
|
---|
48 | #endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.