KD Chart 2
[rev.2.7]
|
Auxiliary class used by the KDChart::Measure and KDChart::Chart class. More...
#include <KDChartMeasure.h>
Public Member Functions | |
GlobalMeasureScaling () | |
virtual | ~GlobalMeasureScaling () |
Static Public Member Functions | |
static const QPair< qreal, qreal > | currentFactors () |
Return the currently active factors. More... | |
static GlobalMeasureScaling * | instance () |
static QPaintDevice * | paintDevice () |
Return the paint device to use for calculating font metrics. More... | |
static void | resetFactors () |
Restore factors to the values before the previous call to setFactors. More... | |
static void | setFactors (qreal factorX, qreal factorY) |
Set new factors to be used by all Measure objects from now on. More... | |
static void | setPaintDevice (QPaintDevice *paintDevice) |
Set the paint device to use for calculating font metrics. More... | |
Auxiliary class used by the KDChart::Measure and KDChart::Chart class.
Normally there should be no need to call any of these methods yourself.
They are used by KDChart::Chart::paint( QPainter*, const QRect& ) to adjust all of the relative Measures according to the target rectangle's size.
Default factors are (1.0, 1.0)
Definition at line 140 of file KDChartMeasure.h.
KDChart::GlobalMeasureScaling::GlobalMeasureScaling | ( | ) |
Definition at line 188 of file KDChartMeasure.cpp.
|
virtual |
Definition at line 194 of file KDChartMeasure.cpp.
|
static |
Return the currently active factors.
Definition at line 217 of file KDChartMeasure.cpp.
References instance().
Referenced by KDChart::Measure::sizeOfArea().
|
static |
Definition at line 199 of file KDChartMeasure.cpp.
Referenced by currentFactors(), KDChart::Chart::paint(), paintDevice(), resetFactors(), setFactors(), setPaintDevice(), and KDChart::Measure::sizeOfArea().
|
static |
Return the paint device to use for calculating font metrics.
Definition at line 227 of file KDChartMeasure.cpp.
References instance().
Referenced by KDChart::CartesianAxis::maximumSize(), KDChart::Chart::paint(), setPaintDevice(), KDChart::TextLayoutItem::sizeHintUnrotated(), and updateToplevelLayout().
|
static |
Restore factors to the values before the previous call to setFactors.
The current values are popped off a stack internally.
Definition at line 210 of file KDChartMeasure.cpp.
References instance().
Referenced by KDChart::Chart::paint().
|
static |
Set new factors to be used by all Measure objects from now on.
Previous values will be saved on a stack internally.
Definition at line 205 of file KDChartMeasure.cpp.
References instance().
Referenced by KDChart::Chart::paint().
|
static |
Set the paint device to use for calculating font metrics.
Definition at line 222 of file KDChartMeasure.cpp.
References instance(), and paintDevice().
Referenced by KDChart::Chart::paint().