| 1 | // Copyright (C) 2016 The Qt Company Ltd. |
|---|---|
| 2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only |
| 3 | #ifndef QBARLEGENDMARKER_H |
| 4 | #define QBARLEGENDMARKER_H |
| 5 | |
| 6 | #include <QtCharts/QChartGlobal> |
| 7 | #include <QtCharts/QLegendMarker> |
| 8 | #include <QtCharts/QAbstractBarSeries> |
| 9 | #include <QtCharts/QBarSet> |
| 10 | |
| 11 | QT_BEGIN_NAMESPACE |
| 12 | |
| 13 | class QLegend; |
| 14 | class QBarLegendMarkerPrivate; |
| 15 | |
| 16 | class Q_CHARTS_EXPORT QBarLegendMarker : public QLegendMarker |
| 17 | { |
| 18 | Q_OBJECT |
| 19 | public: |
| 20 | explicit QBarLegendMarker(QAbstractBarSeries *series, QBarSet *barset, QLegend *legend, QObject *parent = nullptr); |
| 21 | virtual ~QBarLegendMarker(); |
| 22 | |
| 23 | LegendMarkerType type() override { return LegendMarkerTypeBar; } |
| 24 | |
| 25 | // Related series and barset |
| 26 | QAbstractBarSeries* series() override; |
| 27 | QBarSet* barset(); |
| 28 | |
| 29 | protected: |
| 30 | QBarLegendMarker(QBarLegendMarkerPrivate &d, QObject *parent = nullptr); |
| 31 | |
| 32 | private: |
| 33 | Q_DECLARE_PRIVATE(QBarLegendMarker) |
| 34 | Q_DISABLE_COPY(QBarLegendMarker) |
| 35 | |
| 36 | }; |
| 37 | |
| 38 | QT_END_NAMESPACE |
| 39 | |
| 40 | #endif // QBARLEGENDMARKER_H |
| 41 |
