blob: b5536dc8a42a65e7ee6468ca0a58a6edbdbefbd8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
// Copyright (C) 2016 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
#ifndef DONUTBREAKDOWNCHART_H
#define DONUTBREAKDOWNCHART_H
#include <QtCharts/QChart>
#include <QtCharts/QPieSeries>
QT_USE_NAMESPACE
class DonutBreakdownChart : public QChart
{
public:
DonutBreakdownChart(QGraphicsItem *parent = nullptr, Qt::WindowFlags wFlags = {});
void addBreakdownSeries(QPieSeries *series, QColor color);
private:
void recalculateAngles();
void updateLegendMarkers();
private:
QPieSeries *m_mainSeries;
};
#endif // DONUTBREAKDOWNCHART_H
|