diff options
author | Tomi Korpipaa <tomi.korpipaa@qt.io> | 2022-02-10 07:02:44 +0200 |
---|---|---|
committer | Tomi Korpipaa <tomi.korpipaa@qt.io> | 2022-02-10 11:17:48 +0200 |
commit | e82f53b35010dbeae6a5e7d87e007518a4eb0cbb (patch) | |
tree | 9a74a62a30a0fd0b43408f9bafc90114f9a24fe1 /src | |
parent | 3928bd7b188b15a6f712a9d3650ced2d0b872545 (diff) |
Fix API review finding
Rename wireFrameColor to wireframeColor to be
consistent with other usage of wirfeframe in
QtDataVisualization.
Pick-to: 6.3
Change-Id: I1ae6cd7372e46efa2a5d83856126d45355fcff60
Reviewed-by: Sami Varanka <sami.varanka@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/datavisualization/data/qsurface3dseries.cpp | 22 | ||||
-rw-r--r-- | src/datavisualization/data/qsurface3dseries.h | 8 | ||||
-rw-r--r-- | src/datavisualization/data/qsurface3dseries_p.h | 4 | ||||
-rw-r--r-- | src/datavisualization/engine/drawer.cpp | 2 | ||||
-rw-r--r-- | src/datavisualization/engine/surfaceseriesrendercache.cpp | 2 | ||||
-rw-r--r-- | src/datavisualization/utils/surfaceobject_p.h | 6 |
6 files changed, 22 insertions, 22 deletions
diff --git a/src/datavisualization/data/qsurface3dseries.cpp b/src/datavisualization/data/qsurface3dseries.cpp index f3e8e1fa..492d572e 100644 --- a/src/datavisualization/data/qsurface3dseries.cpp +++ b/src/datavisualization/data/qsurface3dseries.cpp @@ -166,7 +166,7 @@ QT_BEGIN_NAMESPACE */ /*! - * \qmlproperty color Surface3DSeries::wireFrameColor + * \qmlproperty color Surface3DSeries::wireframeColor * \since 6.3 * * The color used to draw the gridlines of the surface wireframe. @@ -405,22 +405,22 @@ QString QSurface3DSeries::textureFile() const } /*! - * \property QSurface3DSeries::wireFrameColor + * \property QSurface3DSeries::wireframeColor * \since 6.3 * * \brief The color for the surface wireframe. */ -void QSurface3DSeries::setWireFrameColor(const QColor &color) +void QSurface3DSeries::setWireframeColor(const QColor &color) { - if (dptr()->m_wireFrameColor != color) { - dptr()->setWireFrameColor(color); - emit wireFrameColorChanged(color); + if (dptr()->m_wireframeColor != color) { + dptr()->setWireframeColor(color); + emit wireframeColorChanged(color); } } -QColor QSurface3DSeries::wireFrameColor() const +QColor QSurface3DSeries::wireframeColor() const { - return dptrc()->m_wireFrameColor; + return dptrc()->m_wireframeColor; } /*! * \internal @@ -445,7 +445,7 @@ QSurface3DSeriesPrivate::QSurface3DSeriesPrivate(QSurface3DSeries *q) m_selectedPoint(Surface3DController::invalidSelectionPosition()), m_flatShadingEnabled(true), m_drawMode(QSurface3DSeries::DrawSurfaceAndWireframe), - m_wireFrameColor(Qt::black) + m_wireframeColor(Qt::black) { m_itemLabelFormat = QStringLiteral("@xLabel, @yLabel, @zLabel"); m_mesh = QAbstract3DSeries::MeshSphere; @@ -578,9 +578,9 @@ void QSurface3DSeriesPrivate::setTexture(const QImage &texture) static_cast<Surface3DController *>(m_controller)->updateSurfaceTexture(qptr()); } -void QSurface3DSeriesPrivate::setWireFrameColor(const QColor &color) +void QSurface3DSeriesPrivate::setWireframeColor(const QColor &color) { - m_wireFrameColor = color; + m_wireframeColor = color; if (m_controller) m_controller->markSeriesVisualsDirty(); } diff --git a/src/datavisualization/data/qsurface3dseries.h b/src/datavisualization/data/qsurface3dseries.h index 508cbba0..59c61dad 100644 --- a/src/datavisualization/data/qsurface3dseries.h +++ b/src/datavisualization/data/qsurface3dseries.h @@ -48,7 +48,7 @@ class Q_DATAVISUALIZATION_EXPORT QSurface3DSeries : public QAbstract3DSeries Q_PROPERTY(DrawFlags drawMode READ drawMode WRITE setDrawMode NOTIFY drawModeChanged) Q_PROPERTY(QImage texture READ texture WRITE setTexture NOTIFY textureChanged) Q_PROPERTY(QString textureFile READ textureFile WRITE setTextureFile NOTIFY textureFileChanged) - Q_PROPERTY(QColor wireFrameColor READ wireFrameColor WRITE setWireFrameColor NOTIFY wireFrameColorChanged REVISION(6, 3)) + Q_PROPERTY(QColor wireframeColor READ wireframeColor WRITE setWireframeColor NOTIFY wireframeColorChanged REVISION(6, 3)) public: enum DrawFlag { @@ -82,8 +82,8 @@ public: void setTextureFile(const QString &filename); QString textureFile() const; - void setWireFrameColor(const QColor &color); - QColor wireFrameColor() const; + void setWireframeColor(const QColor &color); + QColor wireframeColor() const; Q_SIGNALS: void dataProxyChanged(QSurfaceDataProxy *proxy); @@ -93,7 +93,7 @@ Q_SIGNALS: void drawModeChanged(QSurface3DSeries::DrawFlags mode); void textureChanged(const QImage &image); void textureFileChanged(const QString &filename); - Q_REVISION(6, 3) void wireFrameColorChanged(const QColor &color); + Q_REVISION(6, 3) void wireframeColorChanged(const QColor &color); protected: explicit QSurface3DSeries(QSurface3DSeriesPrivate *d, QObject *parent = nullptr); diff --git a/src/datavisualization/data/qsurface3dseries_p.h b/src/datavisualization/data/qsurface3dseries_p.h index 3b35cd22..b1b1a4cb 100644 --- a/src/datavisualization/data/qsurface3dseries_p.h +++ b/src/datavisualization/data/qsurface3dseries_p.h @@ -60,7 +60,7 @@ public: void setFlatShadingEnabled(bool enabled); void setDrawMode(QSurface3DSeries::DrawFlags mode); void setTexture(const QImage &texture); - void setWireFrameColor(const QColor &color); + void setWireframeColor(const QColor &color); private: QSurface3DSeries *qptr(); @@ -70,7 +70,7 @@ private: QSurface3DSeries::DrawFlags m_drawMode; QImage m_texture; QString m_textureFile; - QColor m_wireFrameColor; + QColor m_wireframeColor; private: friend class QSurface3DSeries; diff --git a/src/datavisualization/engine/drawer.cpp b/src/datavisualization/engine/drawer.cpp index 853e800b..8b2dcc15 100644 --- a/src/datavisualization/engine/drawer.cpp +++ b/src/datavisualization/engine/drawer.cpp @@ -198,7 +198,7 @@ void Drawer::drawSelectionObject(ShaderHelper *shader, AbstractObjectHelper *obj void Drawer::drawSurfaceGrid(ShaderHelper *shader, SurfaceObject *object) { // Get grid line color - QVector4D lineColor = Utils::vectorFromColor(object->wireFrameColor()); + QVector4D lineColor = Utils::vectorFromColor(object->wireframeColor()); shader->setUniformValue(shader->color(), lineColor); // 1st attribute buffer : vertices diff --git a/src/datavisualization/engine/surfaceseriesrendercache.cpp b/src/datavisualization/engine/surfaceseriesrendercache.cpp index 545cee7e..11c573fa 100644 --- a/src/datavisualization/engine/surfaceseriesrendercache.cpp +++ b/src/datavisualization/engine/surfaceseriesrendercache.cpp @@ -66,7 +66,7 @@ void SurfaceSeriesRenderCache::populate(bool newSeries) QSurface3DSeries::DrawFlags drawMode = series()->drawMode(); m_surfaceVisible = drawMode.testFlag(QSurface3DSeries::DrawSurface); m_surfaceGridVisible = drawMode.testFlag(QSurface3DSeries::DrawWireframe); - QColor lineColor = series()->wireFrameColor(); + QColor lineColor = series()->wireframeColor(); m_surfaceObj->setLineColor(lineColor); m_sliceSurfaceObj->setLineColor(lineColor); diff --git a/src/datavisualization/utils/surfaceobject_p.h b/src/datavisualization/utils/surfaceobject_p.h index 9e317bb2..dd9db348 100644 --- a/src/datavisualization/utils/surfaceobject_p.h +++ b/src/datavisualization/utils/surfaceobject_p.h @@ -96,8 +96,8 @@ public: float minYValue() const { return m_minY; } float maxYValue() const { return m_maxY; } inline void activateSurfaceTexture(bool value) { m_returnTextureBuffer = value; } - inline void setLineColor(const QColor &color) { m_wireFrameColor = color; } - inline const QColor &wireFrameColor() const { return m_wireFrameColor; } + inline void setLineColor(const QColor &color) { m_wireframeColor = color; } + inline const QColor &wireframeColor() const { return m_wireframeColor; } private: void createCoarseIndices(GLint *indices, int &p, int row, int upperRow, int j); @@ -132,7 +132,7 @@ private: bool m_returnTextureBuffer = false; SurfaceObject::DataDimensions m_dataDimension; SurfaceObject::DataDimensions m_oldDataDimension = DataDimensions(-1); - QColor m_wireFrameColor; + QColor m_wireframeColor; }; QT_END_NAMESPACE |