KD Chart API Documentation 3.1
|
Base class for AbstractArea and AbstractAreaWidget: An area in the chart with a background, a frame, etc. More...
#include <KDChartAbstractAreaBase.h>
Public Member Functions | |
void | alignToReferencePoint (const RelativePosition &position) |
BackgroundAttributes | backgroundAttributes () const |
bool | compare (const AbstractAreaBase *other) const |
FrameAttributes | frameAttributes () const |
void | getFrameLeadings (int &left, int &top, int &right, int &bottom) const |
virtual void | paintBackground (QPainter &painter, const QRect &rectangle) |
virtual void | paintFrame (QPainter &painter, const QRect &rectangle) |
void | setBackgroundAttributes (const BackgroundAttributes &a) |
void | setFrameAttributes (const FrameAttributes &a) |
Static Public Member Functions | |
static void | paintBackgroundAttributes (QPainter &painter, const QRect &rectangle, const KDChart::BackgroundAttributes &attributes) |
static void | paintFrameAttributes (QPainter &painter, const QRect &rectangle, const KDChart::FrameAttributes &attributes) |
Protected Member Functions | |
AbstractAreaBase () | |
virtual | ~AbstractAreaBase () |
virtual QRect | areaGeometry () const =0 |
QRect | innerRect () const |
virtual void | positionHasChanged () |
Base class for AbstractArea and AbstractAreaWidget: An area in the chart with a background, a frame, etc.
AbstractAreaBase is the base class for all chart elements that have a set of background attributes and frame attributes, such as legends or axes.
Definition at line 51 of file KDChartAbstractAreaBase.h.
|
protected |
Definition at line 38 of file KDChartAbstractAreaBase.cpp.
|
protectedvirtual |
Definition at line 43 of file KDChartAbstractAreaBase.cpp.
void AbstractAreaBase::alignToReferencePoint | ( | const RelativePosition & | position | ) |
Definition at line 65 of file KDChartAbstractAreaBase.cpp.
|
protectedpure virtual |
Implemented in KDChart::AbstractArea, KDChart::AbstractAreaWidget, and KDChart::TextArea.
Referenced by innerRect().
BackgroundAttributes AbstractAreaBase::backgroundAttributes | ( | ) | const |
Definition at line 95 of file KDChartAbstractAreaBase.cpp.
References d.
Referenced by compare(), and updateCommonBrush().
bool AbstractAreaBase::compare | ( | const AbstractAreaBase * | other | ) | const |
Returns true if both areas have the same settings.
Definition at line 55 of file KDChartAbstractAreaBase.cpp.
References backgroundAttributes(), and frameAttributes().
Referenced by KDChart::Legend::compare().
FrameAttributes AbstractAreaBase::frameAttributes | ( | ) | const |
Definition at line 81 of file KDChartAbstractAreaBase.cpp.
References d.
Referenced by KDChart::Legend::clone(), compare(), and updateCommonBrush().
void AbstractAreaBase::getFrameLeadings | ( | int & | left, |
int & | top, | ||
int & | right, | ||
int & | bottom | ||
) | const |
Definition at line 190 of file KDChartAbstractAreaBase.cpp.
References d.
Referenced by innerRect(), and KDChart::AbstractAreaWidget::paintAll().
|
protected |
Definition at line 202 of file KDChartAbstractAreaBase.cpp.
References QRect::adjusted(), areaGeometry(), and getFrameLeadings().
Referenced by KDChart::AbstractArea::paintAll(), and KDChart::TextArea::paintAll().
Definition at line 168 of file KDChartAbstractAreaBase.cpp.
References QPainterPath::addRoundedRect(), QRect::adjusted(), d, paintBackgroundAttributes(), and QPainter::setClipPath().
Referenced by KDChart::AbstractAreaWidget::paintAll(), KDChart::AbstractArea::paintAll(), and KDChart::TextArea::paintAll().
|
static |
Definition at line 101 of file KDChartAbstractAreaBase.cpp.
References QRect::adjusted(), KDChart::BackgroundAttributes::BackgroundPixmapModeCentered, KDChart::BackgroundAttributes::BackgroundPixmapModeNone, KDChart::BackgroundAttributes::BackgroundPixmapModeScaled, KDChart::BackgroundAttributes::BackgroundPixmapModeStretched, KDChart::BackgroundAttributes::brush(), QRect::center(), QPainter::deviceTransform(), QPainter::drawPixmap(), QPainter::drawRect(), QRect::height(), QPixmap::height(), QPixmap::isNull(), KDChart::BackgroundAttributes::isVisible(), QTransform::map(), Qt::NoBrush, Qt::NoPen, KDChart::BackgroundAttributes::pixmap(), KDChart::BackgroundAttributes::pixmapMode(), QTransform::scale(), QPainter::setBrush(), QPainter::setBrushOrigin(), QPainter::setPen(), QPointF::setX(), QPointF::setY(), QBrush::style(), QRect::topLeft(), QPixmap::transformed(), QRect::width(), QPixmap::width(), QPoint::x(), and QPoint::y().
Referenced by paintBackground().
Definition at line 183 of file KDChartAbstractAreaBase.cpp.
References d, and paintFrameAttributes().
Referenced by KDChart::AbstractAreaWidget::paintAll(), KDChart::AbstractArea::paintAll(), and KDChart::TextArea::paintAll().
|
static |
Definition at line 147 of file KDChartAbstractAreaBase.cpp.
References QRect::adjusted(), QPainter::brush(), KDChart::FrameAttributes::cornerRadius(), QPainter::drawRoundedRect(), KDChart::FrameAttributes::isVisible(), Qt::NoBrush, KDChart::FrameAttributes::pen(), QPainter::pen(), KDChart::PrintingParameters::scalePen(), QPainter::setBrush(), and QPainter::setPen().
Referenced by paintFrame().
|
protectedvirtual |
Reimplemented in KDChart::AbstractArea, KDChart::AbstractAreaWidget, and KDChart::TextArea.
Definition at line 212 of file KDChartAbstractAreaBase.cpp.
Referenced by setBackgroundAttributes(), and setFrameAttributes().
void AbstractAreaBase::setBackgroundAttributes | ( | const BackgroundAttributes & | a | ) |
Definition at line 86 of file KDChartAbstractAreaBase.cpp.
References d, and positionHasChanged().
void AbstractAreaBase::setFrameAttributes | ( | const FrameAttributes & | a | ) |
Definition at line 72 of file KDChartAbstractAreaBase.cpp.
References d, and positionHasChanged().