KD Chart 2
[rev.2.7]
|
An area in the chart with a background, a frame, etc. More...
#include <KDChartAbstractAreaWidget.h>
Signals | |
void | positionChanged (AbstractAreaWidget *) |
Public Member Functions | |
AbstractAreaWidget (QWidget *parent=0) | |
void | alignToReferencePoint (const RelativePosition &position) |
BackgroundAttributes | backgroundAttributes () const |
bool | compare (const AbstractAreaBase *other) const |
Returns true if both areas have the same settings. More... | |
virtual void | forceRebuild () |
Call this to trigger an unconditional re-building of the widget's internals. More... | |
FrameAttributes | frameAttributes () const |
void | getFrameLeadings (int &left, int &top, int &right, int &bottom) const |
virtual void | needSizeHint () |
Call this to trigger an conditional re-building of the widget's internals. More... | |
virtual void | paint (QPainter *painter)=0 |
Overwrite this to paint the inner contents of your widget. More... | |
void | paintAll (QPainter &painter) |
Call paintAll, if you want the background and the frame to be drawn before the normal paint() is invoked automatically. More... | |
virtual void | paintBackground (QPainter &painter, const QRect &rectangle) |
void | paintEvent (QPaintEvent *event) override |
Draws the background and frame, then calls paint(). More... | |
virtual void | paintFrame (QPainter &painter, const QRect &rectangle) |
virtual void | paintIntoRect (QPainter &painter, const QRect &rect) |
Draws the background and frame, then calls paint(). More... | |
virtual void | resizeLayout (const QSize &) |
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 | |
QRect | areaGeometry () const override |
QRect | innerRect () const |
void | positionHasChanged () override |
~AbstractAreaWidget () override | |
An area in the chart with a background, a frame, etc.
AbstractAreaWidget is the base for all widget classes that have a set of background attributes and frame attributes, such as KDChart::Chart and KDChart::Legend.
Definition at line 44 of file KDChartAbstractAreaWidget.h.
|
explicit |
Definition at line 65 of file KDChartAbstractAreaWidget.cpp.
|
overrideprotected |
Definition at line 72 of file KDChartAbstractAreaWidget.cpp.
|
inherited |
Definition at line 81 of file KDChartAbstractAreaBase.cpp.
|
overrideprotectedvirtual |
Implements KDChart::AbstractAreaBase.
Definition at line 179 of file KDChartAbstractAreaWidget.cpp.
Referenced by updateToplevelLayout().
|
inherited |
Definition at line 111 of file KDChartAbstractAreaBase.cpp.
References d.
Referenced by KDChart::AbstractAreaBase::compare(), and updateCommonBrush().
|
inherited |
Returns true if both areas have the same settings.
Definition at line 71 of file KDChartAbstractAreaBase.cpp.
References KDChart::AbstractAreaBase::backgroundAttributes(), and KDChart::AbstractAreaBase::frameAttributes().
Referenced by KDChart::Legend::compare().
|
virtual |
Call this to trigger an unconditional re-building of the widget's internals.
Reimplemented in KDChart::Legend.
Definition at line 135 of file KDChartAbstractAreaWidget.cpp.
|
inherited |
Definition at line 97 of file KDChartAbstractAreaBase.cpp.
References d.
Referenced by KDChart::Legend::clone(), KDChart::AbstractAreaBase::compare(), and updateCommonBrush().
|
inherited |
Definition at line 213 of file KDChartAbstractAreaBase.cpp.
References d.
Referenced by KDChart::AbstractAreaBase::innerRect(), and paintAll().
|
protectedinherited |
Definition at line 225 of file KDChartAbstractAreaBase.cpp.
References KDChart::AbstractAreaBase::areaGeometry(), and KDChart::AbstractAreaBase::getFrameLeadings().
Referenced by KDChart::AbstractArea::paintAll(), and KDChart::TextArea::paintAll().
|
virtual |
Call this to trigger an conditional re-building of the widget's internals.
e.g. AbstractAreaWidget call this, before calling layout()->setGeometry()
Reimplemented in KDChart::Legend.
Definition at line 82 of file KDChartAbstractAreaWidget.cpp.
|
pure virtual |
Overwrite this to paint the inner contents of your widget.
Implemented in KDChart::Legend.
Referenced by paintAll().
void AbstractAreaWidget::paintAll | ( | QPainter & | painter | ) |
Call paintAll, if you want the background and the frame to be drawn before the normal paint() is invoked automatically.
Definition at line 140 of file KDChartAbstractAreaWidget.cpp.
References KDChart::AbstractAreaBase::getFrameLeadings(), paint(), KDChart::AbstractAreaBase::paintBackground(), and KDChart::AbstractAreaBase::paintFrame().
Referenced by paintEvent(), and paintIntoRect().
|
virtualinherited |
Definition at line 189 of file KDChartAbstractAreaBase.cpp.
References d, and KDChart::AbstractAreaBase::paintBackgroundAttributes().
Referenced by KDChart::AbstractArea::paintAll(), KDChart::TextArea::paintAll(), and paintAll().
|
staticinherited |
Definition at line 118 of file KDChartAbstractAreaBase.cpp.
References KDChart::BackgroundAttributes::BackgroundPixmapModeCentered, KDChart::BackgroundAttributes::BackgroundPixmapModeNone, KDChart::BackgroundAttributes::BackgroundPixmapModeScaled, KDChart::BackgroundAttributes::BackgroundPixmapModeStretched, KDChart::BackgroundAttributes::brush(), KDChart::BackgroundAttributes::isVisible(), KDChart::BackgroundAttributes::pixmap(), and KDChart::BackgroundAttributes::pixmapMode().
Referenced by findSharingAxisDiagrams(), and KDChart::AbstractAreaBase::paintBackground().
|
override |
Draws the background and frame, then calls paint().
In most cases there is no need to overwrite this method in a derived class, but you would overwrite paint() instead.
Definition at line 95 of file KDChartAbstractAreaWidget.cpp.
References d, and paintAll().
|
virtualinherited |
Definition at line 205 of file KDChartAbstractAreaBase.cpp.
References d, and KDChart::AbstractAreaBase::paintFrameAttributes().
Referenced by KDChart::AbstractArea::paintAll(), KDChart::TextArea::paintAll(), and paintAll().
|
staticinherited |
Definition at line 168 of file KDChartAbstractAreaBase.cpp.
References KDChart::FrameAttributes::cornerRadius(), KDChart::FrameAttributes::isVisible(), KDChart::FrameAttributes::pen(), and KDChart::PrintingParameters::scalePen().
Referenced by findSharingAxisDiagrams(), and KDChart::AbstractAreaBase::paintFrame().
|
virtual |
Draws the background and frame, then calls paint().
In most cases there is no need to overwrite this method in a derived class, but you would overwrite paint() instead.
Definition at line 105 of file KDChartAbstractAreaWidget.cpp.
References d, and paintAll().
Referenced by findSharingAxisDiagrams().
|
signal |
Referenced by positionHasChanged(), and KDChart::Legend::setPosition().
|
overrideprotectedvirtual |
Reimplemented from KDChart::AbstractAreaBase.
Definition at line 184 of file KDChartAbstractAreaWidget.cpp.
References positionChanged().
|
virtual |
Reimplemented in KDChart::Legend.
Definition at line 89 of file KDChartAbstractAreaWidget.cpp.
|
inherited |
Definition at line 102 of file KDChartAbstractAreaBase.cpp.
References d, and KDChart::AbstractAreaBase::positionHasChanged().
|
inherited |
Definition at line 88 of file KDChartAbstractAreaBase.cpp.
References d, and KDChart::AbstractAreaBase::positionHasChanged().
Referenced by KDChart::Legend::clone(), and KDChart::Legend::~Legend().