@@ -115,13 +115,11 MainWidget::MainWidget(QWidget* parent) | |||
|
115 | 115 | m_endAngle->setValue(m_series->pieEndAngle()); |
|
116 | 116 | m_endAngle->setSingleStep(1); |
|
117 | 117 | |
|
118 |
m_ |
|
|
119 | ||
|
120 | m_donutInnerSize = new QDoubleSpinBox(); | |
|
121 |
m_ |
|
|
122 | m_donutInnerSize->setMaximum(1.0); | |
|
123 | m_donutInnerSize->setSingleStep(0.1); | |
|
124 | m_donutInnerSize->setValue(m_series->donutInnerSize()); | |
|
118 | m_holeSize = new QDoubleSpinBox(); | |
|
119 | m_holeSize->setMinimum(0.0); | |
|
120 | m_holeSize->setMaximum(1.0); | |
|
121 | m_holeSize->setSingleStep(0.1); | |
|
122 | m_holeSize->setValue(m_series->holeSize()); | |
|
125 | 123 | |
|
126 | 124 | QPushButton *appendSlice = new QPushButton("Append slice"); |
|
127 | 125 | QPushButton *insertSlice = new QPushButton("Insert slice"); |
@@ -133,8 +131,7 MainWidget::MainWidget(QWidget* parent) | |||
|
133 | 131 | seriesSettingsLayout->addRow("Size factor", m_sizeFactor); |
|
134 | 132 | seriesSettingsLayout->addRow("Start angle", m_startAngle); |
|
135 | 133 | seriesSettingsLayout->addRow("End angle", m_endAngle); |
|
136 |
seriesSettingsLayout->addRow(" |
|
|
137 | seriesSettingsLayout->addRow("Donut inner size", m_donutInnerSize); | |
|
134 | seriesSettingsLayout->addRow("Hole size", m_holeSize); | |
|
138 | 135 | seriesSettingsLayout->addRow(appendSlice); |
|
139 | 136 | seriesSettingsLayout->addRow(insertSlice); |
|
140 | 137 | seriesSettingsLayout->addRow(removeSlice); |
@@ -146,8 +143,7 MainWidget::MainWidget(QWidget* parent) | |||
|
146 | 143 | connect(m_sizeFactor, SIGNAL(valueChanged(double)), this, SLOT(updateSerieSettings())); |
|
147 | 144 | connect(m_startAngle, SIGNAL(valueChanged(double)), this, SLOT(updateSerieSettings())); |
|
148 | 145 | connect(m_endAngle, SIGNAL(valueChanged(double)), this, SLOT(updateSerieSettings())); |
|
149 |
connect(m_ |
|
|
150 | connect(m_donutInnerSize, SIGNAL(valueChanged(double)), this, SLOT(updateSerieSettings())); | |
|
146 | connect(m_holeSize, SIGNAL(valueChanged(double)), this, SLOT(updateSerieSettings())); | |
|
151 | 147 | connect(appendSlice, SIGNAL(clicked()), this, SLOT(appendSlice())); |
|
152 | 148 | connect(insertSlice, SIGNAL(clicked()), this, SLOT(insertSlice())); |
|
153 | 149 | connect(removeSlice, SIGNAL(clicked()), this, SLOT(removeSlice())); |
@@ -249,10 +245,10 void MainWidget::updateSerieSettings() | |||
|
249 | 245 | m_series->setHorizontalPosition(m_hPosition->value()); |
|
250 | 246 | m_series->setVerticalPosition(m_vPosition->value()); |
|
251 | 247 | m_series->setPieSize(m_sizeFactor->value()); |
|
248 | m_holeSize->setMaximum(m_sizeFactor->value()); | |
|
252 | 249 | m_series->setPieStartAngle(m_startAngle->value()); |
|
253 | 250 | m_series->setPieEndAngle(m_endAngle->value()); |
|
254 |
m_series->set |
|
|
255 | m_series->setDonutInnerSize(m_donutInnerSize->value()); | |
|
251 | m_series->setHoleSize(m_holeSize->value()); | |
|
256 | 252 | } |
|
257 | 253 | |
|
258 | 254 | void MainWidget::updateSliceSettings() |
@@ -72,8 +72,7 private: | |||
|
72 | 72 | QDoubleSpinBox* m_sizeFactor; |
|
73 | 73 | QDoubleSpinBox* m_startAngle; |
|
74 | 74 | QDoubleSpinBox* m_endAngle; |
|
75 | QCheckBox* m_isDonut; | |
|
76 | QDoubleSpinBox* m_donutInnerSize; | |
|
75 | QDoubleSpinBox* m_holeSize; | |
|
77 | 76 | |
|
78 | 77 | QLineEdit* m_sliceName; |
|
79 | 78 | QDoubleSpinBox* m_sliceValue; |
@@ -1,5 +1,7 | |||
|
1 | 1 | #include "widget.h" |
|
2 | 2 | #include <QChartView> |
|
3 | #include <QChart> | |
|
4 | #include <QLegend> | |
|
3 | 5 | #include <QPieSeries> |
|
4 | 6 | #include <QPieSlice> |
|
5 | 7 | #include <QTime> |
@@ -17,19 +19,20 Widget::Widget(QWidget *parent) | |||
|
17 | 19 | //! [1] |
|
18 | 20 | QChartView *chartView = new QChartView; |
|
19 | 21 | chartView->setRenderHint(QPainter::Antialiasing); |
|
20 | chartView->chart()->setAnimationOptions(QChart::AllAnimations); | |
|
22 | QChart *chart = chartView->chart(); | |
|
23 | chart->setAnimationOptions(QChart::AllAnimations); | |
|
24 | chart->legend()->setVisible(false); | |
|
21 | 25 | //! [1] |
|
22 | 26 | |
|
23 | 27 | //! [2] |
|
24 | 28 | qreal minSize = 0.1; |
|
25 | 29 | qreal maxSize = 0.9; |
|
26 |
int donut |
|
|
30 | int donutCount = 5; | |
|
27 | 31 | //! [2] |
|
28 | 32 | |
|
29 | 33 | //! [3] |
|
30 |
for (int i = 0; i < donut |
|
|
34 | for (int i = 0; i < donutCount; i++) { | |
|
31 | 35 | QPieSeries *donut = new QPieSeries; |
|
32 | donut->setDonut(); | |
|
33 | 36 | int sliceCount = 3 + qrand() % 3; |
|
34 | 37 | for (int j = 0; j < sliceCount; j++) { |
|
35 | 38 | qreal value = 100 + qrand() % 100; |
@@ -39,8 +42,8 Widget::Widget(QWidget *parent) | |||
|
39 | 42 | slice->setLabelPosition(QPieSlice::LabelInsideTangential); |
|
40 | 43 | connect(slice, SIGNAL(hovered(bool)), this, SLOT(explodeSlice(bool))); |
|
41 | 44 | donut->append(slice); |
|
42 |
donut->set |
|
|
43 |
donut->setPieSize(minSize + (i + 1) * (maxSize - minSize) / donut |
|
|
45 | donut->setHoleSize(minSize + i * (maxSize - minSize) / donutCount); | |
|
46 | donut->setPieSize(minSize + (i + 1) * (maxSize - minSize) / donutCount); | |
|
44 | 47 | } |
|
45 | 48 | m_donuts.append(donut); |
|
46 | 49 | chartView->chart()->addSeries(donut); |
@@ -1,9 +1,10 | |||
|
1 | 1 | #include "widget.h" |
|
2 | 2 | #include <QGridLayout> |
|
3 | ||
|
4 | 3 | #include <QPieSlice> |
|
5 | 4 | #include <QTime> |
|
6 | 5 | #include <QChartView> |
|
6 | #include <QChart> | |
|
7 | #include <QLegend> | |
|
7 | 8 | #include <QTimer> |
|
8 | 9 | |
|
9 | 10 | QTCOMMERCIALCHART_USE_NAMESPACE |
@@ -18,7 +19,9 Widget::Widget(QWidget *parent) | |||
|
18 | 19 | //! [1] |
|
19 | 20 | QChartView *chartView = new QChartView; |
|
20 | 21 | chartView->setRenderHint(QPainter::Antialiasing); |
|
21 | chartView->chart()->setAnimationOptions(QChart::AllAnimations); | |
|
22 | QChart *chart = chartView->chart(); | |
|
23 | chart->setAnimationOptions(QChart::AllAnimations); | |
|
24 | chart->legend()->setVisible(false); | |
|
22 | 25 | //! [1] |
|
23 | 26 | |
|
24 | 27 | //! [2] |
@@ -35,8 +38,7 Widget::Widget(QWidget *parent) | |||
|
35 | 38 | |
|
36 | 39 | // create a new detailed data for the slice |
|
37 | 40 | QPieSeries *donut = new QPieSeries; |
|
38 | donut->setDonut(); | |
|
39 | donut->setDonutInnerSize(mainData->pieSize()); | |
|
41 | donut->setHoleSize(mainData->pieSize()); | |
|
40 | 42 | donut->setPieSize(mainData->pieSize() + 0.15); |
|
41 | 43 | |
|
42 | 44 | // when mainData slice is redrawn make sure the detailed data slices are aligned with it |
@@ -61,8 +61,8 ChartAnimation* PieAnimation::addSlice(PieSliceItem *sliceItem, const PieSliceDa | |||
|
61 | 61 | startValue.m_startAngle = sliceData.m_startAngle + (sliceData.m_angleSpan / 2); |
|
62 | 62 | startValue.m_angleSpan = 0; |
|
63 | 63 | |
|
64 |
if (sliceData.m_ |
|
|
65 |
startValue.m_radius = sliceData.m_ |
|
|
64 | if (sliceData.m_holeRadius > 0) | |
|
65 | startValue.m_radius = sliceData.m_holeRadius; | |
|
66 | 66 | |
|
67 | 67 | animation->setValue(startValue, sliceData); |
|
68 | 68 | animation->setDuration(ChartAnimationDuration); |
@@ -78,8 +78,8 ChartAnimation* PieAnimation::removeSlice(PieSliceItem *sliceItem) | |||
|
78 | 78 | animation->stop(); |
|
79 | 79 | |
|
80 | 80 | PieSliceData endValue = animation->currentSliceValue(); |
|
81 |
if (endValue.m_ |
|
|
82 |
endValue.m_radius = endValue.m_ |
|
|
81 | if (endValue.m_holeRadius > 0) | |
|
82 | endValue.m_radius = endValue.m_holeRadius; | |
|
83 | 83 | else |
|
84 | 84 | endValue.m_radius = 0; |
|
85 | 85 | endValue.m_startAngle = endValue.m_startAngle + endValue.m_angleSpan; |
@@ -110,7 +110,7 QVariant PieSliceAnimation::interpolated(const QVariant &start, const QVariant & | |||
|
110 | 110 | result.m_angleSpan = linearPos(startValue.m_angleSpan, endValue.m_angleSpan, progress); |
|
111 | 111 | result.m_slicePen = linearPos(startValue.m_slicePen, endValue.m_slicePen, progress); |
|
112 | 112 | result.m_sliceBrush = linearPos(startValue.m_sliceBrush, endValue.m_sliceBrush, progress); |
|
113 |
result.m_ |
|
|
113 | result.m_holeRadius = linearPos(startValue.m_holeRadius, endValue.m_holeRadius, progress); | |
|
114 | 114 | |
|
115 | 115 | return qVariantFromValue(result); |
|
116 | 116 | } |
@@ -122,10 +122,10 void PieChartItem::updateLayout() | |||
|
122 | 122 | if (m_rect.width() < m_rect.height()) |
|
123 | 123 | m_pieRadius = m_rect.width() / 2; |
|
124 | 124 | |
|
125 |
m_ |
|
|
125 | m_holeSize = m_pieRadius; | |
|
126 | 126 | // apply size factor |
|
127 | 127 | m_pieRadius *= m_series->pieSize(); |
|
128 |
m_ |
|
|
128 | m_holeSize *= m_series->holeSize(); | |
|
129 | 129 | |
|
130 | 130 | // set layouts for existing slice items |
|
131 | 131 | foreach (QPieSlice* slice, m_series->slices()) { |
@@ -233,8 +233,7 PieSliceData PieChartItem::updateSliceGeometry(QPieSlice *slice) | |||
|
233 | 233 | PieSliceData &sliceData = QPieSlicePrivate::fromSlice(slice)->m_data; |
|
234 | 234 | sliceData.m_center = PieSliceItem::sliceCenter(m_pieCenter, m_pieRadius, slice); |
|
235 | 235 | sliceData.m_radius = m_pieRadius; |
|
236 |
sliceData.m_ |
|
|
237 | sliceData.m_innerRadius = m_donutInnerRadius; | |
|
236 | sliceData.m_holeRadius = m_holeSize; | |
|
238 | 237 | return sliceData; |
|
239 | 238 | } |
|
240 | 239 |
@@ -78,7 +78,7 private: | |||
|
78 | 78 | QRectF m_rect; |
|
79 | 79 | QPointF m_pieCenter; |
|
80 | 80 | qreal m_pieRadius; |
|
81 |
qreal m_ |
|
|
81 | qreal m_holeSize; | |
|
82 | 82 | PieAnimation* m_animation; |
|
83 | 83 | |
|
84 | 84 | }; |
@@ -83,8 +83,7 public: | |||
|
83 | 83 | m_startAngle = 0; |
|
84 | 84 | m_angleSpan = 0; |
|
85 | 85 | |
|
86 |
m_ |
|
|
87 | m_innerRadius = 0; | |
|
86 | m_holeRadius = 0; | |
|
88 | 87 | } |
|
89 | 88 | |
|
90 | 89 | bool operator!=(const PieSliceData &other) const |
@@ -139,8 +138,7 public: | |||
|
139 | 138 | qreal m_startAngle; |
|
140 | 139 | qreal m_angleSpan; |
|
141 | 140 | |
|
142 | bool m_donut; | |
|
143 | qreal m_innerRadius; | |
|
141 | qreal m_holeRadius; | |
|
144 | 142 | }; |
|
145 | 143 | |
|
146 | 144 | QTCOMMERCIALCHART_END_NAMESPACE |
@@ -172,8 +172,8 void PieSliceItem::updateGeometry() | |||
|
172 | 172 | case QPieSlice::LabelInsideTangential: |
|
173 | 173 | case QPieSlice::LabelInsideNormal:{ |
|
174 | 174 | QPointF textCenter; |
|
175 |
if (m_data.m_ |
|
|
176 |
textCenter = m_data.m_center + offset(centerAngle, m_data.m_ |
|
|
175 | if (m_data.m_holeRadius > 0) | |
|
176 | textCenter = m_data.m_center + offset(centerAngle, m_data.m_holeRadius + (m_data.m_radius - m_data.m_holeRadius) / 2); | |
|
177 | 177 | else |
|
178 | 178 | textCenter = m_data.m_center + offset(centerAngle, m_data.m_radius / 2); |
|
179 | 179 | m_labelTextRect.moveCenter(textCenter); |
@@ -208,8 +208,8 QPainterPath PieSliceItem::slicePath(QPointF center, qreal radius, qreal startAn | |||
|
208 | 208 | |
|
209 | 209 | // slice path |
|
210 | 210 | QPainterPath path; |
|
211 |
if (m_data.m_ |
|
|
212 |
QRectF insideRect(center.x() - m_data.m_ |
|
|
211 | if (m_data.m_holeRadius > 0) { | |
|
212 | QRectF insideRect(center.x() - m_data.m_holeRadius, center.y()-m_data.m_holeRadius, m_data.m_holeRadius*2, m_data.m_holeRadius*2); | |
|
213 | 213 | path.arcMoveTo(rect, -startAngle + 90); |
|
214 | 214 | path.arcTo(rect, -startAngle + 90, -angleSpan); |
|
215 | 215 | path.arcTo(insideRect, -startAngle + 90 - angleSpan, angleSpan); |
@@ -132,7 +132,7 QTCOMMERCIALCHART_BEGIN_NAMESPACE | |||
|
132 | 132 | \o 1.0 is the maximum size that can fit the chart. |
|
133 | 133 | \endlist |
|
134 | 134 | |
|
135 |
When setting this property the |
|
|
135 | When setting this property the holeSize property is adjusted if necessary, to ensure that the hole size is not greater than the outer size. | |
|
136 | 136 | |
|
137 | 137 | Default value is 0.7. |
|
138 | 138 | */ |
@@ -153,35 +153,35 QTCOMMERCIALCHART_BEGIN_NAMESPACE | |||
|
153 | 153 | */ |
|
154 | 154 | |
|
155 | 155 | /*! |
|
156 |
\property QPieSeries:: |
|
|
157 |
\brief Defines the donut |
|
|
156 | \property QPieSeries::holeSize | |
|
157 | \brief Defines the donut hole size. | |
|
158 | 158 | |
|
159 | 159 | The value is a relative value to the chart rectangle where: |
|
160 | 160 | |
|
161 | 161 | \list |
|
162 |
\o 0.0 is the minimum size (pie not |
|
|
162 | \o 0.0 is the minimum size (full pie drawn, without any hole inside). | |
|
163 | 163 | \o 1.0 is the maximum size that can fit the chart. (donut has no width) |
|
164 | 164 | \endlist |
|
165 | 165 | |
|
166 | 166 | The value is never greater then size property. |
|
167 |
Default value is 0. |
|
|
167 | Default value is 0.0. | |
|
168 | 168 | */ |
|
169 | 169 | |
|
170 | 170 | /*! |
|
171 |
\qmlproperty real PieSeries:: |
|
|
171 | \qmlproperty real PieSeries::holeSize | |
|
172 | 172 | |
|
173 |
Defines the donut |
|
|
173 | Defines the donut hole size. | |
|
174 | 174 | |
|
175 | 175 | The value is a relative value to the chart rectangle where: |
|
176 | 176 | |
|
177 | 177 | \list |
|
178 |
\o 0.0 is the minimum size (do |
|
|
178 | \o 0.0 is the minimum size (full pie drawn, without any hole inside). | |
|
179 | 179 | \o 1.0 is the maximum size that can fit the chart. (donut has no width) |
|
180 | 180 | \endlist |
|
181 | 181 | |
|
182 | 182 | When setting this property the size property is adjusted if necessary, to ensure that the inner size is not greater than the outer size. |
|
183 | 183 | |
|
184 |
Default value is 0. |
|
|
184 | Default value is 0.0. | |
|
185 | 185 | */ |
|
186 | 186 | |
|
187 | 187 | /*! |
@@ -235,18 +235,6 QTCOMMERCIALCHART_BEGIN_NAMESPACE | |||
|
235 | 235 | */ |
|
236 | 236 | |
|
237 | 237 | /*! |
|
238 | \property QPieSeries::donut | |
|
239 | ||
|
240 | Defines whether the series should be drawn as a donut | |
|
241 | */ | |
|
242 | ||
|
243 | /*! | |
|
244 | \qmlproperty int PieSeries::donut | |
|
245 | ||
|
246 | Defines whether the series should be drawn as a donut | |
|
247 | */ | |
|
248 | ||
|
249 | /*! | |
|
250 | 238 | \fn void QPieSeries::countChanged() |
|
251 | 239 | Emitted when the slice count has changed. |
|
252 | 240 | \sa count |
@@ -594,30 +582,17 qreal QPieSeries::sum() const | |||
|
594 | 582 | return d->m_sum; |
|
595 | 583 | } |
|
596 | 584 | |
|
597 |
void QPieSeries::set |
|
|
598 | { | |
|
599 | Q_D(QPieSeries); | |
|
600 | d->m_donutChart = donut; | |
|
601 | d->updateDerivativeData(); | |
|
602 | } | |
|
603 | ||
|
604 | bool QPieSeries::donut() const | |
|
605 | { | |
|
606 | Q_D(const QPieSeries); | |
|
607 | return d->m_donutChart; | |
|
608 | } | |
|
609 | ||
|
610 | void QPieSeries::setDonutInnerSize(qreal innerSize) | |
|
585 | void QPieSeries::setHoleSize(qreal holeSize) | |
|
611 | 586 | { |
|
612 | 587 | Q_D(QPieSeries); |
|
613 |
|
|
|
614 |
d->setSizes( |
|
|
588 | holeSize = qBound((qreal)0.0, holeSize, (qreal)1.0); | |
|
589 | d->setSizes(holeSize, qMax(d->m_pieRelativeSize, holeSize)); | |
|
615 | 590 | } |
|
616 | 591 | |
|
617 |
qreal QPieSeries:: |
|
|
592 | qreal QPieSeries::holeSize() const | |
|
618 | 593 | { |
|
619 | 594 | Q_D(const QPieSeries); |
|
620 |
return d->m_ |
|
|
595 | return d->m_holeRelativeSize; | |
|
621 | 596 | } |
|
622 | 597 | |
|
623 | 598 | void QPieSeries::setHorizontalPosition(qreal relativePosition) |
@@ -666,7 +641,7 void QPieSeries::setPieSize(qreal relativeSize) | |||
|
666 | 641 | { |
|
667 | 642 | Q_D(QPieSeries); |
|
668 | 643 | relativeSize = qBound((qreal)0.0, relativeSize, (qreal)1.0); |
|
669 |
d->setSizes(qMin(d->m_ |
|
|
644 | d->setSizes(qMin(d->m_holeRelativeSize, relativeSize), relativeSize); | |
|
670 | 645 | |
|
671 | 646 | } |
|
672 | 647 | |
@@ -766,8 +741,8 QPieSeriesPrivate::QPieSeriesPrivate(QPieSeries *parent) : | |||
|
766 | 741 | m_pieStartAngle(0), |
|
767 | 742 | m_pieEndAngle(360), |
|
768 | 743 | m_sum(0), |
|
769 | m_donutChart(false), | |
|
770 |
m_ |
|
|
744 | // m_donutChart(false), | |
|
745 | m_holeRelativeSize(0.0) | |
|
771 | 746 | { |
|
772 | 747 | } |
|
773 | 748 | |
@@ -811,8 +786,8 void QPieSeriesPrivate::setSizes(qreal innerSize, qreal outerSize) | |||
|
811 | 786 | { |
|
812 | 787 | bool changed = false; |
|
813 | 788 | |
|
814 |
if (!qFuzzyIsNull(m_ |
|
|
815 |
m_ |
|
|
789 | if (!qFuzzyIsNull(m_holeRelativeSize - innerSize)) { | |
|
790 | m_holeRelativeSize = innerSize; | |
|
816 | 791 | changed = true; |
|
817 | 792 | } |
|
818 | 793 |
@@ -38,8 +38,8 class QTCOMMERCIALCHART_EXPORT QPieSeries : public QAbstractSeries | |||
|
38 | 38 | Q_PROPERTY(qreal endAngle READ pieEndAngle WRITE setPieEndAngle) |
|
39 | 39 | Q_PROPERTY(int count READ count NOTIFY countChanged) |
|
40 | 40 | Q_PROPERTY(qreal sum READ sum NOTIFY sumChanged) |
|
41 |
Q_PROPERTY(qreal |
|
|
42 | Q_PROPERTY(bool donut READ donut WRITE setDonut) | |
|
41 | Q_PROPERTY(qreal holeSize READ holeSize WRITE setHoleSize) | |
|
42 | // Q_PROPERTY(bool donut READ donut WRITE setDonut) | |
|
43 | 43 | |
|
44 | 44 | public: |
|
45 | 45 | explicit QPieSeries(QObject *parent = 0); |
@@ -65,11 +65,8 public: | |||
|
65 | 65 | |
|
66 | 66 | qreal sum() const; |
|
67 | 67 | |
|
68 | void setDonut(bool donut = true); | |
|
69 |
|
|
|
70 | ||
|
71 | void setDonutInnerSize(qreal innerSize); | |
|
72 | qreal donutInnerSize() const; | |
|
68 | void setHoleSize(qreal holeSize); | |
|
69 | qreal holeSize() const; | |
|
73 | 70 | |
|
74 | 71 | void setHorizontalPosition(qreal relativePosition); |
|
75 | 72 | qreal horizontalPosition() const; |
@@ -76,8 +76,7 private: | |||
|
76 | 76 | qreal m_pieStartAngle; |
|
77 | 77 | qreal m_pieEndAngle; |
|
78 | 78 | qreal m_sum; |
|
79 | bool m_donutChart; | |
|
80 | qreal m_donutRelativeInnerSize; | |
|
79 | qreal m_holeRelativeSize; | |
|
81 | 80 | |
|
82 | 81 | private: |
|
83 | 82 | friend class QLegendPrivate; |
@@ -129,21 +129,19 void tst_qpieseries::properties() | |||
|
129 | 129 | |
|
130 | 130 | m_series->setPieSize(0.7); |
|
131 | 131 | QCOMPARE(m_series->pieSize(), 0.7); |
|
132 | m_series->setDonut(); | |
|
133 | QVERIFY(m_series->donut()); | |
|
134 | 132 | |
|
135 |
m_series->set |
|
|
136 |
QCOMPARE(m_series-> |
|
|
137 |
m_series->set |
|
|
138 |
QCOMPARE(m_series-> |
|
|
133 | m_series->setHoleSize(-1.0); | |
|
134 | QCOMPARE(m_series->holeSize(), 0.0); | |
|
135 | m_series->setHoleSize(0.5); | |
|
136 | QCOMPARE(m_series->holeSize(), 0.5); | |
|
139 | 137 | |
|
140 |
m_series->set |
|
|
141 |
QCOMPARE(m_series-> |
|
|
138 | m_series->setHoleSize(0.8); | |
|
139 | QCOMPARE(m_series->holeSize(), 0.8); | |
|
142 | 140 | QCOMPARE(m_series->pieSize(), 0.8); |
|
143 | 141 | |
|
144 | 142 | m_series->setPieSize(0.4); |
|
145 | 143 | QCOMPARE(m_series->pieSize(), 0.4); |
|
146 |
QCOMPARE(m_series-> |
|
|
144 | QCOMPARE(m_series->holeSize(), 0.4); | |
|
147 | 145 | |
|
148 | 146 | m_series->setPieStartAngle(0); |
|
149 | 147 | m_series->setPieStartAngle(-180); |
General Comments 0
You need to be logged in to leave comments.
Login now