##// END OF EJS Templates
Fix crash when changing the values to empty model with logarithmic axis...
Miikka Heikkinen -
r2427:b3d485323aa9
parent child
Show More
@@ -76,7 +76,8 Bug Fixes
76 76 - Fixed: Using setLineVisible(false) on a QBarCategoryAxis gives blurry text
77 77 - Fixed: Set the range to min and max for default axes from previously added series
78 78 - Fixed: Axes use incorrect bounding rectangle to calculate sizeHint when labels are in non-default angle
79 - Fixes: Axis titles can slightly overlap with axis labels and axis lines
79 - Fixed: Axis titles can slightly overlap with axis labels and axis lines
80 - Fixed: Charts crashes when changing the values to empty model with logarithmic axis
80 81
81 82 Known Issues
82 83 ============
@@ -84,16 +84,15 void XYChart::handlePointAdded(int index)
84 84
85 85 QVector<QPointF> points;
86 86
87 if (m_dirty) {
87 if (m_dirty || m_points.isEmpty()) {
88 88 points = domain()->calculateGeometryPoints(m_series->points());
89 89 } else {
90 90 points = m_points;
91 91 QPointF point = domain()->calculateGeometryPoint(m_series->points()[index], m_validData);
92 if (!m_validData) {
92 if (!m_validData)
93 93 m_points.clear();
94 return;
95 }
96 points.insert(index, point);
94 else
95 points.insert(index, point);
97 96 }
98 97
99 98 updateChart(m_points, points, index);
@@ -106,7 +105,7 void XYChart::handlePointRemoved(int index)
106 105
107 106 QVector<QPointF> points;
108 107
109 if (m_dirty) {
108 if (m_dirty || m_points.isEmpty()) {
110 109 points = domain()->calculateGeometryPoints(m_series->points());
111 110 } else {
112 111 points = m_points;
@@ -123,16 +122,15 void XYChart::handlePointReplaced(int index)
123 122
124 123 QVector<QPointF> points;
125 124
126 if (m_dirty) {
125 if (m_dirty || m_points.isEmpty()) {
127 126 points = domain()->calculateGeometryPoints(m_series->points());
128 127 } else {
129 128 QPointF point = domain()->calculateGeometryPoint(m_series->points()[index], m_validData);
130 if (!m_validData) {
129 if (!m_validData)
131 130 m_points.clear();
132 return;
133 }
134 131 points = m_points;
135 points.replace(index, point);
132 if (m_validData)
133 points.replace(index, point);
136 134 }
137 135
138 136 updateChart(m_points, points, index);
General Comments 0
You need to be logged in to leave comments. Login now