diff options
author | Tomi Korpipää <tomi.korpipaa@digia.com> | 2013-09-03 08:21:22 +0300 |
---|---|---|
committer | Tomi Korpipää <tomi.korpipaa@digia.com> | 2013-09-03 08:43:59 +0300 |
commit | de88514dba523734170652d75a5cefcc7feb7c6c (patch) | |
tree | 649f908f09720f02c949782dfac7847a1b62f9c6 /tests/scattertest/scatterchart.h | |
parent | 7b988086e9976b78d0f1ff433dcec205c6d33478 (diff) |
Fixed issues from Improve examples task
Task-number: QTRD-2239
+ Moved extra-full examples to tests
+ Removed extra functionality from widget and scatterchart examples
+ Changed bars default to bevelbar
+ Changed default label style to nobackground
Change-Id: Idffba7a44d5b54dbaf36d7cdbfe616b78e0d4073
Reviewed-by: Mika Salmela <mika.salmela@digia.com>
Diffstat (limited to 'tests/scattertest/scatterchart.h')
-rw-r--r-- | tests/scattertest/scatterchart.h | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/tests/scattertest/scatterchart.h b/tests/scattertest/scatterchart.h new file mode 100644 index 00000000..4412af99 --- /dev/null +++ b/tests/scattertest/scatterchart.h @@ -0,0 +1,77 @@ +/**************************************************************************** +** +** Copyright (C) 2013 Digia Plc +** All rights reserved. +** For any questions to Digia, please use contact form at http://qt.digia.com +** +** This file is part of the QtDataVis3D module. +** +** Licensees holding valid Qt Enterprise licenses may use this file in +** accordance with the Qt Enterprise License Agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. +** +** If you have questions regarding the use of this file, please use +** contact form at http://qt.digia.com +** +****************************************************************************/ + +#ifndef SCATTERDATAMODIFIER_H +#define SCATTERDATAMODIFIER_H + +#include <QtDataVis3D/q3dscatter.h> + +#include <QFont> +#include <QDebug> +#include <QTimer> + +using namespace QtDataVis3D; + +class ScatterDataModifier : public QObject +{ + Q_OBJECT +public: + explicit ScatterDataModifier(Q3DScatter *scatter); + ~ScatterDataModifier(); + + void addData(); + void changeStyle(); + void changePresetCamera(); + void changeTheme(); + void changeTransparency(); + void changeFont(const QFont &font); + void changeFontSize(int fontsize); + void setBackgroundEnabled(int enabled); + void setGridEnabled(int enabled); + void start(); + +public slots: + void changeShadowQuality(int quality); + void shadowQualityUpdatedByVisual(QDataVis::ShadowQuality shadowQuality); + void clear(); + void addOne(); + void addBunch(); + void insertOne(); + void insertBunch(); + void changeOne(); + void changeBunch(); + void removeOne(); + void removeBunch(); + void timeout(); + void startStopTimer(); + void selectItem(); + void handleSelectionChange(int index); + +signals: + void shadowQualityChanged(int quality); + +private: + QVector3D randVector(); + Q3DScatter *m_chart; + int m_fontSize; + QTimer m_timer; + int m_loopCounter; + int m_selectedItem; +}; + +#endif |