summaryrefslogtreecommitdiff
path: root/src/svg/qsvgstyle_p.h
diff options
context:
space:
mode:
authorKim Motoyoshi Kalland <kim.kalland@nokia.com>2009-04-03 10:47:07 +0200
committerKim Motoyoshi Kalland <kim.kalland@nokia.com>2009-04-03 11:50:06 +0200
commit6c2dd295b2ca2f9125fe072d035a3784ce748718 (patch)
tree565f5ba97690df7891a598c699e50e741444911e /src/svg/qsvgstyle_p.h
parentd684546573785ce40fb5de2b8b3aad88e9958709 (diff)
downloadqt4-tools-6c2dd295b2ca2f9125fe072d035a3784ce748718.tar.gz
Removed usage of NaN in SVG gradients.
Since there is no way to find out if gradient stops have been added to a gradient, a gradient stop at NaN was earlier used in the SVG module to mark the gradient as empty. This could cause floating point exceptions. The usage of NaN has now been replaced by a boolean in QSvgGradientStyle. Duplicate entry "qxmlpatterns" was removed from auto.pro in the auto test directory. Task-number: 250146 Reviewed-by: Samuel
Diffstat (limited to 'src/svg/qsvgstyle_p.h')
-rw-r--r--src/svg/qsvgstyle_p.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/svg/qsvgstyle_p.h b/src/svg/qsvgstyle_p.h
index ff4058b265..058ba3583d 100644
--- a/src/svg/qsvgstyle_p.h
+++ b/src/svg/qsvgstyle_p.h
@@ -376,6 +376,16 @@ public:
}
void addResolve(qreal offset);
+
+ bool gradientStopsSet() const
+ {
+ return m_gradientStopsSet;
+ }
+
+ void setGradientStopsSet(bool set)
+ {
+ m_gradientStopsSet = set;
+ }
private:
QGradient *m_gradient;
QList<qreal> m_resolvePoints;
@@ -386,6 +396,7 @@ private:
QSvgTinyDocument *m_doc;
QString m_link;
+ bool m_gradientStopsSet;
};
class QSvgTransformStyle : public QSvgStyleProperty