fix Scatter3D::clear

This commit is contained in:
2023-10-24 12:29:55 +03:00
parent dc5075ad8a
commit 9fee5a7d07
2 changed files with 7 additions and 1 deletions

View File

@@ -117,6 +117,12 @@ void Scatter3D::removeGraphic(int index) {
}
void Scatter3D::clear() {
for (auto g: graphics)
g.data->resetArray(nullptr);
}
void Scatter3D::setLabelAutoRotation(bool on) {
if (on) {
canvas->axisX()->setLabelAutoRotation(90);

View File

@@ -75,7 +75,7 @@ public slots:
void setGraphicMeshSmooth(bool smooth) { setGraphicMeshSmooth(smooth, curGraphic); }
void addGraphic(const QColor & color = Qt::darkBlue, float pointSize = 1.f, Mesh mesh = Mesh::MeshSphere, bool meshSmooth = true);
void removeGraphic(int index);
void clear() { setGraphicsCount(0); }
void clear();
void setLabelAutoRotation(bool on);
void setGraphicData(const QVector<QVector3D> & points, int index);
void setGraphicData(const QVector<QVector3D> & points) { setGraphicData(points, curGraphic); }