diff options
author | Miikka Heikkinen <miikka.heikkinen@digia.com> | 2014-06-25 13:00:55 +0300 |
---|---|---|
committer | Miikka Heikkinen <miikka.heikkinen@digia.com> | 2014-06-26 10:43:39 +0300 |
commit | 36417dd3660f75c34328c3420bdd512436da86ff (patch) | |
tree | b940d98d8df6a8a64adc1a638c57f20a4a955c5b /src/datavisualization/engine/surface3dcontroller_p.h | |
parent | ec195a34594dea6145af5e8f2fedc2f9401d0f14 (diff) |
Add flipHorizontalGrid property for surface
This property allows drawind the horizontal grid and axis labels on
top of the graph rather than on the bottom. This is useful when
surface graph is used for 2D spectrograms in orthographic mode, as
otherwise the grid is covered by the surface itself. Particularly
relevant for polar plots of the same.
Task-number: QTRD-3184
Change-Id: I9dbcdbfc754e13af52d2cf31a1d9991ef4b241f7
Reviewed-by: Mika Salmela <mika.salmela@digia.com>
Diffstat (limited to 'src/datavisualization/engine/surface3dcontroller_p.h')
-rw-r--r-- | src/datavisualization/engine/surface3dcontroller_p.h | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/datavisualization/engine/surface3dcontroller_p.h b/src/datavisualization/engine/surface3dcontroller_p.h index 2be74f35..653f41c3 100644 --- a/src/datavisualization/engine/surface3dcontroller_p.h +++ b/src/datavisualization/engine/surface3dcontroller_p.h @@ -38,14 +38,16 @@ class Surface3DRenderer; class QSurface3DSeries; struct Surface3DChangeBitField { - bool selectedPointChanged : 1; - bool rowsChanged : 1; - bool itemChanged : 1; + bool selectedPointChanged : 1; + bool rowsChanged : 1; + bool itemChanged : 1; + bool flipHorizontalGridChanged : 1; Surface3DChangeBitField() : selectedPointChanged(true), rowsChanged(false), - itemChanged(false) + itemChanged(false), + flipHorizontalGridChanged(true) { } }; @@ -73,6 +75,7 @@ private: bool m_flatShadingSupported; QVector<ChangeItem> m_changedItems; QVector<ChangeRow> m_changedRows; + bool m_flipHorizontalGrid; public: explicit Surface3DController(QRect rect, Q3DScene *scene = 0); @@ -101,6 +104,9 @@ public: virtual void removeSeries(QAbstract3DSeries *series); virtual QList<QSurface3DSeries *> surfaceSeriesList(); + void setFlipHorizontalGrid(bool flip); + bool flipHorizontalGrid() const; + public slots: void handleArrayReset(); void handleRowsAdded(int startIndex, int count); @@ -113,6 +119,7 @@ public slots: signals: void selectedSeriesChanged(QSurface3DSeries *series); + void flipHorizontalGridChanged(bool flip); private: Q_DISABLE_COPY(Surface3DController) |