KD Chart 2  [rev.2.7]
Public Member Functions | List of all members
KDChart::Measure Class Reference

Measure is used to specify relative and absolute sizes in KDChart, e.g. More...

#include <KDChartMeasure>

Public Member Functions

qreal calculatedValue (const QObject *autoArea, KDChartEnums::MeasureOrientation autoOrientation) const
 The reference area must either be derived from AbstractArea or from QWidget, so it can also be derived from AbstractAreaWidget. More...
 
qreal calculatedValue (const QSizeF &autoSize, KDChartEnums::MeasureOrientation autoOrientation) const
 
KDChartEnums::MeasureCalculationMode calculationMode () const
 
 Measure ()
 
 Measure (qreal value, KDChartEnums::MeasureCalculationMode mode=KDChartEnums::MeasureCalculationModeAuto, KDChartEnums::MeasureOrientation orientation=KDChartEnums::MeasureOrientationAuto)
 
 Measure (const Measure &)
 
bool operator!= (const Measure &other) const
 
Measureoperator= (const Measure &)
 
bool operator== (const Measure &) const
 
const QObjectreferenceArea () const
 The returned reference area will be derived from AbstractArea or QWidget or both. More...
 
KDChartEnums::MeasureOrientation referenceOrientation () const
 
void setAbsoluteValue (qreal val)
 This is a convenience method for specifying a value, implicitly setting the calculation mode to MeasureCalculationModeAbsolute. More...
 
void setCalculationMode (KDChartEnums::MeasureCalculationMode mode)
 
void setReferenceArea (const QObject *area)
 The reference area must either be derived from AbstractArea or from QWidget, so it can also be derived from AbstractAreaWidget. More...
 
void setReferenceOrientation (KDChartEnums::MeasureOrientation orientation)
 
void setRelativeMode (const QObject *area, KDChartEnums::MeasureOrientation orientation)
 The reference area must either be derived from AbstractArea or from QWidget, so it can also be derived from AbstractAreaWidget. More...
 
void setValue (qreal val)
 
const QSizeF sizeOfArea (const QObject *area) const
 
qreal value () const
 

Detailed Description

Measure is used to specify relative and absolute sizes in KDChart, e.g.

font sizes.

Definition at line 51 of file KDChartMeasure.h.

Constructor & Destructor Documentation

KDChart::Measure::Measure ( )

Definition at line 39 of file KDChartMeasure.cpp.

Definition at line 48 of file KDChartMeasure.cpp.

KDChart::Measure::Measure ( const Measure r)

Definition at line 59 of file KDChartMeasure.cpp.

Member Function Documentation

qreal KDChart::Measure::calculatedValue ( const QObject autoArea,
KDChartEnums::MeasureOrientation  autoOrientation 
) const

The reference area must either be derived from AbstractArea or from QWidget, so it can also be derived from AbstractAreaWidget.

Definition at line 137 of file KDChartMeasure.cpp.

References sizeOfArea().

Referenced by KDChart::TextAttributes::calculatedFontSize(), and KDChart::RelativePosition::calculatedPoint().

qreal KDChart::Measure::calculatedValue ( const QSizeF &  autoSize,
KDChartEnums::MeasureOrientation  autoOrientation 
) const
KDChartEnums::MeasureCalculationMode KDChart::Measure::calculationMode ( ) const

Definition at line 65 of file KDChartMeasure.h.

Referenced by operator<<(), operator=(), and operator==().

bool KDChart::Measure::operator!= ( const Measure other) const

Definition at line 118 of file KDChartMeasure.h.

References KDGantt::operator==().

Measure & KDChart::Measure::operator= ( const Measure r)

Definition at line 68 of file KDChartMeasure.cpp.

References calculationMode(), referenceArea(), referenceOrientation(), and value().

bool KDChart::Measure::operator== ( const Measure r) const
const QObject* KDChart::Measure::referenceArea ( ) const

The returned reference area will be derived from AbstractArea or QWidget or both.

Definition at line 104 of file KDChartMeasure.h.

Referenced by operator<<(), operator=(), and operator==().

KDChartEnums::MeasureOrientation KDChart::Measure::referenceOrientation ( ) const

Definition at line 107 of file KDChartMeasure.h.

References KDGantt::operator==().

Referenced by operator<<(), operator=(), and operator==().

void KDChart::Measure::setAbsoluteValue ( qreal  val)

This is a convenience method for specifying a value, implicitly setting the calculation mode to MeasureCalculationModeAbsolute.

Calling setAbsoluteValue( value ) is the same as calling

    setValue( value );
    setCalculationMode( KDChartEnums::MeasureCalculationModeAbsolute );

Definition at line 89 of file KDChartMeasure.h.

References KDChartEnums::MeasureCalculationModeAbsolute.

void KDChart::Measure::setCalculationMode ( KDChartEnums::MeasureCalculationMode  mode)
void KDChart::Measure::setReferenceArea ( const QObject area)

The reference area must either be derived from AbstractArea or from QWidget, so it can also be derived from AbstractAreaWidget.

Definition at line 99 of file KDChartMeasure.h.

void KDChart::Measure::setReferenceOrientation ( KDChartEnums::MeasureOrientation  orientation)

Definition at line 106 of file KDChartMeasure.h.

void KDChart::Measure::setRelativeMode ( const QObject area,
KDChartEnums::MeasureOrientation  orientation 
)

The reference area must either be derived from AbstractArea or from QWidget, so it can also be derived from AbstractAreaWidget.

Definition at line 71 of file KDChartMeasure.h.

References KDChartEnums::MeasureCalculationModeRelative.

Referenced by KDChart::Chart::addHeaderFooter(), KDChart::Chart::addLegend(), and KDChart::HeaderFooter::setParent().

void KDChart::Measure::setValue ( qreal  val)
const QSizeF KDChart::Measure::sizeOfArea ( const QObject area) const
qreal KDChart::Measure::value ( ) const

Definition at line 62 of file KDChartMeasure.h.

Referenced by calculatedValue(), operator<<(), operator=(), operator==(), and rotatedRect().


The documentation for this class was generated from the following files:

Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/

https://www.kdab.com/development-resources/qt-tools/kd-chart/