##// END OF EJS Templates
Fixed bug in setting chart theme...
Fixed bug in setting chart theme The bug was that if you first add a series, then change theme and then restore the original theme, the color of the series was changed even though it should have been restored to match the original color.

File last commit:

r186:a60a21158b5a
r312:0677c9dd6d92
Show More
qlinechartseries.h
48 lines | 1.1 KiB | text/x-c | CLexer
Michal Klocek
Fix naming convention for lineseries...
r144 #ifndef QLINECHARTSERIES_H_
#define QLINECHARTSERIES_H_
Tero Ahola
Started to refactor the API to allow integrating different plot types
r19
Tero Ahola
Renamed to QtCommercialChart
r30 #include "qchartglobal.h"
Michal Klocek
Refactor current draft to fit int current design specs...
r21 #include "qchartseries.h"
Michal Klocek
adds missing files form previous commit
r12 #include <QDebug>
Michal Klocek
Refactora axis and line chart to use graphics items insted of painter.
r85 #include <QPen>
#include <QBrush>
Michal Klocek
adds missing files form previous commit
r12
Tero Ahola
Renamed to QtCommercialChart
r30 QTCOMMERCIALCHART_BEGIN_NAMESPACE
Michal Klocek
adds missing files form previous commit
r12
Michal Klocek
Fix naming convention for lineseries...
r144 class QTCOMMERCIALCHART_EXPORT QLineChartSeries : public QChartSeries
Michal Klocek
adds missing files form previous commit
r12 {
Michal Klocek
Refactors qchart , adds line animation...
r131 Q_OBJECT
Michal Klocek
adds missing files form previous commit
r12 public:
Michal Klocek
Clean up obsolete create metods in series
r156 QLineChartSeries(QObject* parent=0);
Michal Klocek
Fix naming convention for lineseries...
r144 virtual ~QLineChartSeries();
Michal Klocek
Refactor current draft to fit int current design specs...
r21
Tero Ahola
One more alternative for changing themes
r108 public: // from QChartSeries
Tero Ahola
Renamed to QtCommercialChart
r30 virtual QChartSeriesType type() const { return QChartSeries::SeriesTypeLine;}
Michal Klocek
Refactors qchart , adds line animation...
r131 int add(qreal x, qreal y);
void set(int index,qreal x,qreal y);
Michal Klocek
adds missing files form previous commit
r12 void clear();
Michal Klocek
Refactora axis and line chart to use graphics items insted of painter.
r85
void setPen(const QPen& pen);
const QPen& pen() const { return m_pen;}
Michal Klocek
minor. missing setter for line series
r186 void setPointsVisible(bool visible);
Michal Klocek
Add pointsVisible setting for line series
r185 bool isPointsVisible() const {return m_pointsVisible;}
Michal Klocek
adds missing files form previous commit
r12 int count() const;
qreal x(int pos) const;
qreal y(int pos) const;
Michal Klocek
Fix naming convention for lineseries...
r144 friend QDebug operator<< (QDebug d, const QLineChartSeries series);
Michal Klocek
adds missing files form previous commit
r12
Michal Klocek
Refactors qchart , adds line animation...
r131 signals:
void changed(int index);
Michal Klocek
adds missing files form previous commit
r12 private:
Michal Klocek
Refactors qchart , adds line animation...
r131 QVector<qreal> m_x;
QVector<qreal> m_y;
Michal Klocek
Refactora axis and line chart to use graphics items insted of painter.
r85 QPen m_pen;
Michal Klocek
Add pointsVisible setting for line series
r185 bool m_pointsVisible;
Michal Klocek
adds missing files form previous commit
r12 };
Tero Ahola
Renamed to QtCommercialChart
r30 QTCOMMERCIALCHART_END_NAMESPACE
Tero Ahola
Started to refactor the API to allow integrating different plot types
r19
Michal Klocek
adds missing files form previous commit
r12 #endif