##// END OF EJS Templates
Added support for adding and removing data with model. Updated the example
Added support for adding and removing data with model. Updated the example

File last commit:

r540:7d8a0757e05d
r545:366c5163e81a
Show More
charttheme_p.h
72 lines | 2.2 KiB | text/x-c | CLexer
Tero Ahola
Refactored themes; now enabled for line, scatter and pies...
r103 #ifndef CHARTTHEME_H
#define CHARTTHEME_H
#include "qchartglobal.h"
Michal Klocek
Refactor themes...
r143 #include "qchart.h"
Tero Ahola
Refactored themes; now enabled for line, scatter and pies...
r103 #include <QColor>
Jani Honkonen
Adding list of series gradients to theme.
r494 #include <QGradientStops>
Tero Ahola
Refactored themes; now enabled for line, scatter and pies...
r103
QTCOMMERCIALCHART_BEGIN_NAMESPACE
Michal Klocek
Refactor themes...
r143 class ChartItem;
Michal Klocek
Rename QChartSeries to QSeries
r360 class QSeries;
Michal Klocek
Fix previous broken commit
r145 class LineChartItem;
Michal Klocek
Rename QLineChartSeries to QLineSeries
r349 class QLineSeries;
sauimone
Common naming convention for barcharts
r216 class BarPresenter;
sauimone
Naming convention change for barcharts. QBarChartSeries is now QBarSeries etc.
r338 class QBarSeries;
sauimone
Common naming convention for barcharts
r216 class StackedBarPresenter;
sauimone
Naming convention change for barcharts. QBarChartSeries is now QBarSeries etc.
r338 class QStackedBarSeries;
class QPercentBarSeries;
sauimone
Common naming convention for barcharts
r216 class PercentBarPresenter;
Tero Ahola
Enabled theme colors in scatter again
r182 class QScatterSeries;
Michal Klocek
Refactor scatter chart to fit the other classes...
r470 class ScatterChartItem;
Jani Honkonen
Make pie work better with chartwidgettest
r163 class PiePresenter;
class QPieSeries;
Marek Rosa
Renamed SplinePresenter to SplineChartItem
r460 class SplineChartItem;
Marek Rosa
Spline working somewhat
r401 class QSplineSeries;
Michal Klocek
Adds area chart...
r421 class AreaChartItem;
class QAreaSeries;
Michal Klocek
Refactor themes...
r143
class ChartTheme
Tero Ahola
Refactored themes; now enabled for line, scatter and pies...
r103 {
Michal Klocek
Refactor themes...
r143 protected:
Michal Klocek
Adds missing ids to theme classes
r153 explicit ChartTheme(QChart::ChartTheme id = QChart::ChartThemeDefault);
Tero Ahola
Refactored themes; now enabled for line, scatter and pies...
r103 public:
Michal Klocek
Adds missing ids to theme classes
r153 static ChartTheme* createTheme(QChart::ChartTheme theme);
QChart::ChartTheme id() const {return m_id;}
Michal Klocek
Refactor themes...
r143 void decorate(QChart* chart);
sauimone
background to legend, theme applies
r540 void decorate(QLegend* legend);
Tero Ahola
Fixed bug with changing theme when several series exist
r538 //void decorate(ChartItem* item, QSeries* series,int index);
void decorate(BarPresenter* item, QBarSeries* series, int index);
void decorate(StackedBarPresenter* item, QStackedBarSeries* series, int index);
void decorate(PercentBarPresenter* item, QPercentBarSeries* series, int index);
void decorate(LineChartItem* item, QLineSeries* series, int index);
void decorate(AreaChartItem* item, QAreaSeries* series, int index);
void decorate(ScatterChartItem* presenter, QScatterSeries* series, int index);
void decorate(PiePresenter* item, QPieSeries* series, int index);
Michal Klocek
Refactors axis handling...
r223 void decorate(QChartAxis* axis,AxisItem* item);
Tero Ahola
Fixed bug with changing theme when several series exist
r538 void decorate(SplineChartItem* presenter, QSplineSeries* series, int index);
Michal Klocek
Refactor themes...
r143
Jani Honkonen
Adding list of series gradients to theme.
r494 public: // utils
Tero Ahola
Theme gradients now generated from a single base color
r507 void generateSeriesGradients();
Jani Honkonen
Adding list of series gradients to theme.
r494 static QColor colorAt(const QColor &start, const QColor &end, qreal pos);
static QColor colorAt(const QGradient &gradient, qreal pos);
Michal Klocek
Refactor themes...
r143 protected:
Michal Klocek
Adds missing ids to theme classes
r153 QChart::ChartTheme m_id;
Jani Honkonen
Adding list of series gradients to theme.
r494 QList<QColor> m_seriesColors;
QList<QGradient> m_seriesGradients;
QLinearGradient m_backgroundGradient;
Tero Ahola
Theme gradients now generated from a single base color
r507
// TODO: Add something like the following to themes:
// QPen axisLinePen;
// QPen backgroundHorizontalGridPen;
// QPen backgroundVerticalGridPen;
// // FillAll, FillEverySecondRow, FillEverySecondColumn, FillEverySecondRowAndColumn, FillNone
// int backgroundType;
// QFont masterFont;
Tero Ahola
Refactored themes; now enabled for line, scatter and pies...
r103 };
QTCOMMERCIALCHART_END_NAMESPACE
#endif // CHARTTHEME_H