summaryrefslogtreecommitdiffstats
path: root/examples/charts/chartsgallery/pointconfigurationwidget.h
diff options
context:
space:
mode:
Diffstat (limited to 'examples/charts/chartsgallery/pointconfigurationwidget.h')
-rw-r--r--examples/charts/chartsgallery/pointconfigurationwidget.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/examples/charts/chartsgallery/pointconfigurationwidget.h b/examples/charts/chartsgallery/pointconfigurationwidget.h
new file mode 100644
index 00000000..92aba69d
--- /dev/null
+++ b/examples/charts/chartsgallery/pointconfigurationwidget.h
@@ -0,0 +1,37 @@
+// Copyright (C) 2023 The Qt Company Ltd.
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
+
+#ifndef POINTCONFIGURATIONWIDGET_H
+#define POINTCONFIGURATIONWIDGET_H
+
+#include "contentwidget.h"
+
+#include <QXYSeries>
+
+QT_FORWARD_DECLARE_CLASS(QLineEdit)
+QT_FORWARD_DECLARE_CLASS(QComboBox)
+QT_FORWARD_DECLARE_CLASS(QCheckBox)
+
+typedef QHash<QXYSeries::PointConfiguration, QVariant> PointConfigurations;
+
+class PointConfigurationWidget : public ContentWidget
+{
+ Q_OBJECT
+public:
+ explicit PointConfigurationWidget(QWidget *parent = nullptr);
+
+private:
+ QXYSeries *m_series = nullptr;
+
+ QMetaObject::Connection m_selectInitialPointConnection;
+ int m_selectedPointIndex = -1;
+ PointConfigurations m_selectedPointConfig;
+
+ QLineEdit *m_selectedPointIndexLineEdit = nullptr;
+ QComboBox *m_colorCombobox = nullptr;
+ QComboBox *m_sizeCombobox = nullptr;
+ QCheckBox *m_labelVisibilityCheckbox = nullptr;
+ QLineEdit *m_customLabelLineEdit = nullptr;
+};
+
+#endif