##// END OF EJS Templates
Update pie docs
Jani Honkonen -
r932:fa77b3cd02ea
parent child
Show More
@@ -226,40 +226,63 bool QPieSeriesPrivate::setRealValue(qreal &value, qreal newValue, qreal max, qr
226
226
227 /*!
227 /*!
228 \property QPieSeries::horizontalPosition
228 \property QPieSeries::horizontalPosition
229 \brief Pie horizontal position property
229 \brief Defines the horizontal position of the pie.
230
230
231 By default horizontal position is 0.5 (center).
231 The value is a relative value to the chart rectangle where:
232
233 \list
234 \o 0.0 is the absolute left.
235 \o 1.0 is the absolute right.
236 \endlist
237
238 Default value is 0.5 (center).
232 */
239 */
233
240
234 /*!
241 /*!
235 \property QPieSeries::verticalPosition
242 \property QPieSeries::verticalPosition
236 \brief Pie vertical position property
243 \brief Defines the vertical position of the pie.
244
245 The value is a relative value to the chart rectangle where:
246
247 \list
248 \o 0.0 is the absolute top.
249 \o 1.0 is the absolute bottom.
250 \endlist
237
251
238 By default vertical position is 0.5 (center)
252 Default value is 0.5 (center).
239 */
253 */
240
254
241 /*!
255 /*!
242 \property QPieSeries::size
256 \property QPieSeries::size
243 \brief Pie size property
257 \brief Defines the pie size.
244
258
245 By default size is 0.7.
259 The value is a relative value to the chart rectangle where:
260
261 \list
262 \o 0.0 is the minumum size (pie not drawn).
263 \o 1.0 is the maximum size that can fit the chart.
264 \endlist
265
266 Default value is 0.7.
246 */
267 */
247
268
248 /*!
269 /*!
249 \property QPieSeries::startAngle
270 \property QPieSeries::startAngle
250 \brief Pie start angle.
271 \brief Defines the starting angle of the pie.
251
272
252 Starting angle of the pie. Default is 0.
273 Full pie is 360 degrees where 0 degrees is at 12 a'clock.
253 */
254
274
275 Default is value is 0.
276 */
255
277
256 /*!
278 /*!
257 \property QPieSeries::endAngle
279 \property QPieSeries::endAngle
258 \brief Pie end angle.
280 \brief Defines the ending angle of the pie.
259
281
260 Ending angle of the pie. Default is 360.
282 Full pie is 360 degrees where 0 degrees is at 12 a'clock.
261 */
262
283
284 Default is value is 360.
285 */
263
286
264
287
265 /*!
288 /*!
@@ -443,13 +466,6 QList<QPieSlice*> QPieSeries::slices() const
443 return d->m_slices;
466 return d->m_slices;
444 }
467 }
445
468
446 /*!
447 Sets the horizontal center position of the pie to \a relativePosition. If \a relativePosition is
448 set to 0.0 the pie is drawn on the left side of the chart and if it's set to 1.0 the pie is
449 drawn on right side of the chart. The default value 0.5 puts the pie in the middle.
450
451 \sa setHorizontalPosition(), setPieSize()
452 */
453 void QPieSeries::setHorizontalPosition(qreal relativePosition)
469 void QPieSeries::setHorizontalPosition(qreal relativePosition)
454 {
470 {
455 Q_D(QPieSeries);
471 Q_D(QPieSeries);
@@ -457,13 +473,6 void QPieSeries::setHorizontalPosition(qreal relativePosition)
457 emit piePositionChanged();
473 emit piePositionChanged();
458 }
474 }
459
475
460 /*!
461 Sets the vertical center position of the pie to \a relativePosition. If \a relativePosition is
462 set to 0.0 the pie is drawn on the top of the chart and if it's set to 1.0 the pie is drawn
463 on bottom of the chart. The default value 0.5 puts the pie in the middle.
464
465 \sa verticalPosition(), setPieSize()
466 */
467 void QPieSeries::setVerticalPosition(qreal relativePosition)
476 void QPieSeries::setVerticalPosition(qreal relativePosition)
468 {
477 {
469 Q_D(QPieSeries);
478 Q_D(QPieSeries);
@@ -471,51 +480,18 void QPieSeries::setVerticalPosition(qreal relativePosition)
471 emit piePositionChanged();
480 emit piePositionChanged();
472 }
481 }
473
482
474 /*!
475 Gets the horizontal position of the pie.
476
477 The returned value is relative to the chart rectangle where:
478
479 0.0 means the absolute left.
480 1.0 means the absolute right.
481
482 By default it is 0.5 which puts the pie in the horizontal middle of the chart rectangle.
483
484 \sa verticalPosition(), setPieSize()
485 */
486 qreal QPieSeries::horizontalPosition() const
483 qreal QPieSeries::horizontalPosition() const
487 {
484 {
488 Q_D(const QPieSeries);
485 Q_D(const QPieSeries);
489 return d->m_pieRelativeHorPos;
486 return d->m_pieRelativeHorPos;
490 }
487 }
491
488
492 /*!
493 Gets the vertical position position of the pie.
494
495 The returned value is relative to the chart rectangle where:
496
497 0.0 means the absolute top.
498 1.0 means the absolute bottom.
499
500 By default it is 0.5 which puts the pie in the vertical middle of the chart rectangle.
501
502 \sa horizontalPosition(), setPieSize()
503 */
504 qreal QPieSeries::verticalPosition() const
489 qreal QPieSeries::verticalPosition() const
505 {
490 {
506 Q_D(const QPieSeries);
491 Q_D(const QPieSeries);
507 return d->m_pieRelativeVerPos;
492 return d->m_pieRelativeVerPos;
508 }
493 }
509
494
510 /*!
511 Sets the relative size of the pie.
512
513 The \a relativeSize is defined so that the 1.0 is the maximum that can fit the given chart rectangle.
514
515 Default value is 0.7.
516
517 \sa pieSize(), verticalPosition(), horizontalPosition()
518 */
519 void QPieSeries::setPieSize(qreal relativeSize)
495 void QPieSeries::setPieSize(qreal relativeSize)
520 {
496 {
521 Q_D(QPieSeries);
497 Q_D(QPieSeries);
@@ -523,15 +499,6 void QPieSeries::setPieSize(qreal relativeSize)
523 emit pieSizeChanged();
499 emit pieSizeChanged();
524 }
500 }
525
501
526 /*!
527 Gets the relative size of the pie.
528
529 The size is defined so that the 1.0 is the maximum that can fit the given chart rectangle.
530
531 Default value is 0.7.
532
533 \sa setPieSize(), setPiePosition(), pieVerticalPosition(), pieHorizontalPosition()
534 */
535 qreal QPieSeries::pieSize() const
502 qreal QPieSeries::pieSize() const
536 {
503 {
537 Q_D(const QPieSeries);
504 Q_D(const QPieSeries);
@@ -539,15 +506,6 qreal QPieSeries::pieSize() const
539 }
506 }
540
507
541
508
542 /*!
543 Sets the end angle of the pie.
544
545 Full pie is 360 degrees where 0 degrees is at 12 a'clock.
546
547 \a angle must be less than pie end angle. Default value is 0.
548
549 \sa pieStartAngle(), pieEndAngle(), setPieEndAngle()
550 */
551 void QPieSeries::setPieStartAngle(qreal angle)
509 void QPieSeries::setPieStartAngle(qreal angle)
552 {
510 {
553 Q_D(QPieSeries);
511 Q_D(QPieSeries);
@@ -555,13 +513,6 void QPieSeries::setPieStartAngle(qreal angle)
555 d->updateDerivativeData();
513 d->updateDerivativeData();
556 }
514 }
557
515
558 /*!
559 Gets the start angle of the pie.
560
561 Full pie is 360 degrees where 0 degrees is at 12 a'clock. Default value is 360.
562
563 \sa setPieStartAngle(), pieEndAngle(), setPieEndAngle()
564 */
565 qreal QPieSeries::pieStartAngle() const
516 qreal QPieSeries::pieStartAngle() const
566 {
517 {
567 Q_D(const QPieSeries);
518 Q_D(const QPieSeries);
@@ -254,6 +254,12 qreal QPieSlice::labelArmLengthFactor() const
254 */
254 */
255
255
256 /*!
256 /*!
257 \fn void QPieSlice::selected()
258
259 This signal emitted when this slice has been clicked in the legend.
260 */
261
262 /*!
257 Sets the \a value of this slice.
263 Sets the \a value of this slice.
258 \sa value()
264 \sa value()
259 */
265 */
General Comments 0
You need to be logged in to leave comments. Login now