@@ -27,12 +27,12 QTCOMMERCIALCHART_USE_NAMESPACE | |||||
27 | QChartsPlugin::QChartsPlugin(QObject *parent) : |
|
27 | QChartsPlugin::QChartsPlugin(QObject *parent) : | |
28 | QObject(parent) |
|
28 | QObject(parent) | |
29 | { |
|
29 | { | |
30 | // TODO Auto-generated constructor stub |
|
30 | ||
31 | } |
|
31 | } | |
32 |
|
32 | |||
33 | QChartsPlugin::~QChartsPlugin() |
|
33 | QChartsPlugin::~QChartsPlugin() | |
34 | { |
|
34 | { | |
35 | // TODO Auto-generated destructor stub |
|
35 | ||
36 | } |
|
36 | } | |
37 |
|
37 | |||
38 | QString QChartsPlugin::name() const |
|
38 | QString QChartsPlugin::name() const |
@@ -31,7 +31,6 | |||||
31 |
|
31 | |||
32 | QTCOMMERCIALCHART_BEGIN_NAMESPACE |
|
32 | QTCOMMERCIALCHART_BEGIN_NAMESPACE | |
33 |
|
33 | |||
34 | //TODO: optimize : remove points which are not visible |
|
|||
35 |
|
34 | |||
36 | AreaChartItem::AreaChartItem(QAreaSeries *areaSeries, ChartPresenter *presenter) |
|
35 | AreaChartItem::AreaChartItem(QAreaSeries *areaSeries, ChartPresenter *presenter) | |
37 | : ChartItem(presenter), |
|
36 | : ChartItem(presenter), |
@@ -352,7 +352,7 qreal ChartAxis::minimumHeight() | |||||
352 |
|
352 | |||
353 | void ChartAxis::axisSelected() |
|
353 | void ChartAxis::axisSelected() | |
354 | { |
|
354 | { | |
355 | qDebug()<<"TODO: axis clicked"; |
|
355 | ||
356 | } |
|
356 | } | |
357 |
|
357 | |||
358 |
|
358 |
@@ -127,7 +127,6 void ChartDateTimeAxisX::updateGeometry() | |||||
127 |
|
127 | |||
128 | void ChartDateTimeAxisX::handleAxisUpdated() |
|
128 | void ChartDateTimeAxisX::handleAxisUpdated() | |
129 | { |
|
129 | { | |
130 | //TODO:: fix this |
|
|||
131 | QDateTimeAxis* axis = qobject_cast<QDateTimeAxis*>(m_chartAxis); |
|
130 | QDateTimeAxis* axis = qobject_cast<QDateTimeAxis*>(m_chartAxis); | |
132 | m_tickCount = axis->tickCount(); |
|
131 | m_tickCount = axis->tickCount(); | |
133 | ChartAxis::handleAxisUpdated(); |
|
132 | ChartAxis::handleAxisUpdated(); |
@@ -132,7 +132,6 void ChartDateTimeAxisY::updateGeometry() | |||||
132 |
|
132 | |||
133 | void ChartDateTimeAxisY::handleAxisUpdated() |
|
133 | void ChartDateTimeAxisY::handleAxisUpdated() | |
134 | { |
|
134 | { | |
135 | //TODO:: fix this |
|
|||
136 | QDateTimeAxis* axis = qobject_cast<QDateTimeAxis*>(m_chartAxis); |
|
135 | QDateTimeAxis* axis = qobject_cast<QDateTimeAxis*>(m_chartAxis); | |
137 | m_tickCount = axis->tickCount(); |
|
136 | m_tickCount = axis->tickCount(); | |
138 | ChartAxis::handleAxisUpdated(); |
|
137 | ChartAxis::handleAxisUpdated(); |
@@ -49,7 +49,7 class QDateTimeAxisPrivate : public QAbstractAxisPrivate | |||||
49 | void handleDomainUpdated(); |
|
49 | void handleDomainUpdated(); | |
50 | qreal min(){ return m_min.toMSecsSinceEpoch(); } |
|
50 | qreal min(){ return m_min.toMSecsSinceEpoch(); } | |
51 | qreal max(){ return m_max.toMSecsSinceEpoch(); } |
|
51 | qreal max(){ return m_max.toMSecsSinceEpoch(); } | |
52 |
int count() const { |
|
52 | int count() const { return 0;} | |
53 |
|
53 | |||
54 | protected: |
|
54 | protected: | |
55 | void setMin(const QVariant &min); |
|
55 | void setMin(const QVariant &min); |
@@ -112,7 +112,6 void ChartValueAxisX::updateGeometry() | |||||
112 |
|
112 | |||
113 | void ChartValueAxisX::handleAxisUpdated() |
|
113 | void ChartValueAxisX::handleAxisUpdated() | |
114 | { |
|
114 | { | |
115 | //TODO:: fix this |
|
|||
116 | QValueAxis* axis = qobject_cast<QValueAxis*>(m_chartAxis); |
|
115 | QValueAxis* axis = qobject_cast<QValueAxis*>(m_chartAxis); | |
117 | m_tickCount = axis->tickCount(); |
|
116 | m_tickCount = axis->tickCount(); | |
118 | ChartAxis::handleAxisUpdated(); |
|
117 | ChartAxis::handleAxisUpdated(); |
@@ -117,7 +117,6 void ChartValueAxisY::updateGeometry() | |||||
117 |
|
117 | |||
118 | void ChartValueAxisY::handleAxisUpdated() |
|
118 | void ChartValueAxisY::handleAxisUpdated() | |
119 | { |
|
119 | { | |
120 | //TODO:: fix this |
|
|||
121 | QValueAxis* axis = qobject_cast<QValueAxis*>(m_chartAxis); |
|
120 | QValueAxis* axis = qobject_cast<QValueAxis*>(m_chartAxis); | |
122 | m_tickCount = axis->tickCount(); |
|
121 | m_tickCount = axis->tickCount(); | |
123 | ChartAxis::handleAxisUpdated(); |
|
122 | ChartAxis::handleAxisUpdated(); |
@@ -155,7 +155,6 void ChartDataSet::createAxes(QAbstractAxis::AxisTypes type, Qt::Orientation ori | |||||
155 | { |
|
155 | { | |
156 | QMapIterator<QAbstractSeries*, Domain*> i(m_seriesDomainMap); |
|
156 | QMapIterator<QAbstractSeries*, Domain*> i(m_seriesDomainMap); | |
157 |
|
157 | |||
158 | // TODO: Add a descriptive comment of what happens here |
|
|||
159 | if (type.testFlag(QAbstractAxis::AxisTypeValue) && type.testFlag(QAbstractAxis::AxisTypeBarCategory)) { |
|
158 | if (type.testFlag(QAbstractAxis::AxisTypeValue) && type.testFlag(QAbstractAxis::AxisTypeBarCategory)) { | |
160 | while (i.hasNext()) { |
|
159 | while (i.hasNext()) { | |
161 | i.next(); |
|
160 | i.next(); |
@@ -81,7 +81,6 void ChartLayout::setGeometry(const QRectF& rect) | |||||
81 |
|
81 | |||
82 | QMargins chartMargins = m_chartMargins; |
|
82 | QMargins chartMargins = m_chartMargins; | |
83 |
|
83 | |||
84 | //TODO multiple axis handling; |
|
|||
85 | chartMargins.setLeft(qMax(m_chartMargins.left(),int(axisWidth + 2*m_marginTiny))); |
|
84 | chartMargins.setLeft(qMax(m_chartMargins.left(),int(axisWidth + 2*m_marginTiny))); | |
86 | chartMargins.setBottom(qMax(m_chartMargins.bottom(),int(axisHeight + 2* m_marginTiny))); |
|
85 | chartMargins.setBottom(qMax(m_chartMargins.bottom(),int(axisHeight + 2* m_marginTiny))); | |
87 |
|
86 |
@@ -31,7 +31,7 | |||||
31 | #define CHARTPRESENTER_H |
|
31 | #define CHARTPRESENTER_H | |
32 |
|
32 | |||
33 | #include "qchartglobal.h" |
|
33 | #include "qchartglobal.h" | |
34 | #include "qchart.h" //becouse of QChart::ChartThemeId //TODO |
|
34 | #include "qchart.h" | |
35 | #include <QRectF> |
|
35 | #include <QRectF> | |
36 | #include <QMargins> |
|
36 | #include <QMargins> | |
37 |
|
37 |
@@ -316,9 +316,6 void ChartTheme::generateSeriesGradients() | |||||
316 | qreal h = color.hsvHueF(); |
|
316 | qreal h = color.hsvHueF(); | |
317 | qreal s = color.hsvSaturationF(); |
|
317 | qreal s = color.hsvSaturationF(); | |
318 |
|
318 | |||
319 | // TODO: tune the algorithm to give nice results with most base colors defined in |
|
|||
320 | // most themes. The rest of the gradients we can define manually in theme specific |
|
|||
321 | // implementation. |
|
|||
322 | QColor start = color; |
|
319 | QColor start = color; | |
323 | start.setHsvF(h, 0.0, 1.0); |
|
320 | start.setHsvF(h, 0.0, 1.0); | |
324 | g.setColorAt(0.0, start); |
|
321 | g.setColorAt(0.0, start); |
@@ -154,7 +154,7 QSizeF LegendMarker::sizeHint(Qt::SizeHint which, const QSizeF& constraint) cons | |||||
154 | void LegendMarker::mousePressEvent(QGraphicsSceneMouseEvent *event) |
|
154 | void LegendMarker::mousePressEvent(QGraphicsSceneMouseEvent *event) | |
155 | { |
|
155 | { | |
156 | QGraphicsObject::mousePressEvent(event); |
|
156 | QGraphicsObject::mousePressEvent(event); | |
157 |
qDebug()<<"Not implemented"; |
|
157 | qDebug()<<"Not implemented"; | |
158 | } |
|
158 | } | |
159 |
|
159 | |||
160 | ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// |
|
160 | ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// |
@@ -502,8 +502,6 void QLegendPrivate::handleSeriesRemoved(QAbstractSeries *series) | |||||
502 |
|
502 | |||
503 | void QLegendPrivate::handleSeriesUpdated(QAbstractSeries *series) |
|
503 | void QLegendPrivate::handleSeriesUpdated(QAbstractSeries *series) | |
504 | { |
|
504 | { | |
505 | // TODO: find out which markers are are added or removed. Update them |
|
|||
506 | // TODO: better implementation |
|
|||
507 | handleSeriesRemoved(series); |
|
505 | handleSeriesRemoved(series); | |
508 | Domain domain; |
|
506 | Domain domain; | |
509 | handleSeriesAdded(series, &domain); |
|
507 | handleSeriesAdded(series, &domain); | |
@@ -511,7 +509,6 void QLegendPrivate::handleSeriesUpdated(QAbstractSeries *series) | |||||
511 |
|
509 | |||
512 | void QLegendPrivate::handleUpdatePieSeries() |
|
510 | void QLegendPrivate::handleUpdatePieSeries() | |
513 | { |
|
511 | { | |
514 | //TODO: reimplement to be optimal |
|
|||
515 | QPieSeries* series = qobject_cast<QPieSeries *> (sender()); |
|
512 | QPieSeries* series = qobject_cast<QPieSeries *> (sender()); | |
516 | Q_ASSERT(series); |
|
513 | Q_ASSERT(series); | |
517 | handleSeriesRemoved(series); |
|
514 | handleSeriesRemoved(series); |
@@ -59,7 +59,7 public Q_SLOTS: | |||||
59 | void handleSeriesAdded(QAbstractSeries *series, Domain *domain); |
|
59 | void handleSeriesAdded(QAbstractSeries *series, Domain *domain); | |
60 | void handleSeriesRemoved(QAbstractSeries *series); |
|
60 | void handleSeriesRemoved(QAbstractSeries *series); | |
61 | void handleSeriesUpdated(QAbstractSeries *series); |
|
61 | void handleSeriesUpdated(QAbstractSeries *series); | |
62 |
void handleUpdatePieSeries(); |
|
62 | void handleUpdatePieSeries(); | |
63 | void handleSeriesVisibleChanged(); |
|
63 | void handleSeriesVisibleChanged(); | |
64 |
|
64 | |||
65 | private: |
|
65 | private: |
@@ -162,11 +162,6 QChart* QAbstractSeries::chart() const | |||||
162 | return d_ptr->m_chart; |
|
162 | return d_ptr->m_chart; | |
163 | } |
|
163 | } | |
164 |
|
164 | |||
165 | //void QAbstractSeries::adjustView() |
|
|||
166 | //{ |
|
|||
167 | // //TODO: |
|
|||
168 | //} |
|
|||
169 |
|
||||
170 | /*! |
|
165 | /*! | |
171 | \brief Sets the visibility of the series to true |
|
166 | \brief Sets the visibility of the series to true | |
172 |
|
167 |
@@ -390,15 +390,6 QRectF QChart::plotArea() const | |||||
390 | return d_ptr->m_presenter->geometry(); |
|
390 | return d_ptr->m_presenter->geometry(); | |
391 | } |
|
391 | } | |
392 |
|
392 | |||
393 | ///*! |
|
|||
394 | // TODO: Dummy. |
|
|||
395 | // Adjest the ranges of the axes so that all the data of the specified \a series is visible |
|
|||
396 | // */ |
|
|||
397 | //void QChart::adjustViewToSeries(QAbstractSeries* series) |
|
|||
398 | //{ |
|
|||
399 | // // |
|
|||
400 | //} |
|
|||
401 |
|
||||
402 | /*! |
|
393 | /*! | |
403 | Sets animation \a options for the chart |
|
394 | Sets animation \a options for the chart | |
404 | */ |
|
395 | */ |
@@ -176,7 +176,6 void ScatterChartItem::handleUpdated() | |||||
176 | m_shape = m_series->markerShape(); |
|
176 | m_shape = m_series->markerShape(); | |
177 |
|
177 | |||
178 | if(recreate) { |
|
178 | if(recreate) { | |
179 | // TODO: optimize handleUpdate to recreate points only in case shape changed |
|
|||
180 | deletePoints(count); |
|
179 | deletePoints(count); | |
181 | createPoints(count); |
|
180 | createPoints(count); | |
182 |
|
181 |
@@ -30,8 +30,6 | |||||
30 |
|
30 | |||
31 | QTCOMMERCIALCHART_BEGIN_NAMESPACE |
|
31 | QTCOMMERCIALCHART_BEGIN_NAMESPACE | |
32 |
|
32 | |||
33 | //TODO: optimize : remove points which are not visible |
|
|||
34 |
|
||||
35 | XYChart::XYChart(QXYSeries *series, ChartPresenter *presenter):ChartElement(presenter), |
|
33 | XYChart::XYChart(QXYSeries *series, ChartPresenter *presenter):ChartElement(presenter), | |
36 | m_minX(0), |
|
34 | m_minX(0), | |
37 | m_maxX(0), |
|
35 | m_maxX(0), |
General Comments 0
You need to be logged in to leave comments.
Login now