linechartitem_p.h
43 lines
| 848 B
| text/x-c
|
CLexer
Michal Klocek
|
r144 | #ifndef LINECHARTITEM_H | ||
#define LINECHARTITEM_H | ||||
Michal Klocek
|
r21 | |||
Tero Ahola
|
r30 | #include "qchartglobal.h" | ||
Michal Klocek
|
r465 | #include "xychartitem_p.h" | ||
Michal Klocek
|
r139 | #include <QPen> | ||
Michal Klocek
|
r21 | |||
Tero Ahola
|
r30 | QTCOMMERCIALCHART_BEGIN_NAMESPACE | ||
Michal Klocek
|
r21 | |||
Michal Klocek
|
r349 | class QLineSeries; | ||
Michal Klocek
|
r21 | |||
Michal Klocek
|
r465 | class LineChartItem : public XYChartItem | ||
Michal Klocek
|
r21 | { | ||
Michal Klocek
|
r131 | Q_OBJECT | ||
Michal Klocek
|
r21 | public: | ||
Michal Klocek
|
r470 | explicit LineChartItem(QLineSeries* series,QGraphicsItem *parent = 0); | ||
Michal Klocek
|
r144 | ~ LineChartItem(){}; | ||
Michal Klocek
|
r21 | |||
//from QGraphicsItem | ||||
Michal Klocek
|
r67 | QRectF boundingRect() const; | ||
Tero Ahola
|
r108 | void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget); | ||
Michal Klocek
|
r131 | QPainterPath shape() const; | ||
Michal Klocek
|
r139 | |||
Michal Klocek
|
r389 | public slots: | ||
Michal Klocek
|
r392 | void handleUpdated(); | ||
Michal Klocek
|
r21 | |||
Michal Klocek
|
r464 | protected: | ||
Michal Klocek
|
r557 | void setLayout(QVector<QPointF>& points); | ||
Michal Klocek
|
r464 | |||
Michal Klocek
|
r465 | private: | ||
Marek Rosa
|
r419 | QLineSeries* m_series; | ||
Michal Klocek
|
r391 | QGraphicsItemGroup m_items; | ||
Michal Klocek
|
r465 | QPainterPath m_path; | ||
QRectF m_rect; | ||||
Michal Klocek
|
r544 | QPen m_linePen; | ||
QPen m_pointPen; | ||||
bool m_pointsVisible; | ||||
Michal Klocek
|
r131 | |||
Michal Klocek
|
r21 | }; | ||
Tero Ahola
|
r30 | QTCOMMERCIALCHART_END_NAMESPACE | ||
Michal Klocek
|
r21 | |||
#endif | ||||