declarativelineseries.h
39 lines
| 875 B
| text/x-c
|
CLexer
/ qmlplugin / declarativelineseries.h
Tero Ahola
|
r215 | #ifndef DECLARATIVELINESERIES_H | ||
#define DECLARATIVELINESERIES_H | ||||
#include "qchartglobal.h" | ||||
Tero Ahola
|
r722 | #include "declarativexypoint.h" | ||
Tero Ahola
|
r215 | #include <QDeclarativeItem> | ||
QTCOMMERCIALCHART_BEGIN_NAMESPACE | ||||
class QChart; | ||||
Michal Klocek
|
r349 | class QLineSeries; | ||
Tero Ahola
|
r215 | |||
class DeclarativeLineSeries : public QDeclarativeItem | ||||
{ | ||||
Q_OBJECT | ||||
Tero Ahola
|
r722 | Q_PROPERTY(QDeclarativeListProperty<DeclarativeXyPoint> data READ data) | ||
Tero Ahola
|
r215 | |||
public: | ||||
explicit DeclarativeLineSeries(QDeclarativeItem *parent = 0); | ||||
Tero Ahola
|
r722 | QDeclarativeListProperty<DeclarativeXyPoint> data(); | ||
Tero Ahola
|
r215 | |||
signals: | ||||
public slots: | ||||
Tero Ahola
|
r722 | static void appendData(QDeclarativeListProperty<DeclarativeXyPoint> *list, | ||
DeclarativeXyPoint *element); | ||||
Tero Ahola
|
r215 | |||
private slots: | ||||
void setParentForSeries(); | ||||
private: | ||||
QChart *m_chart; | ||||
Michal Klocek
|
r349 | QLineSeries *m_series; | ||
Tero Ahola
|
r722 | QList<DeclarativeXyPoint *> m_data; | ||
Tero Ahola
|
r215 | }; | ||
QTCOMMERCIALCHART_END_NAMESPACE | ||||
#endif // DECLARATIVELINESERIES_H | ||||