diff options
author | Olivier Goffart <olivier.goffart@nokia.com> | 2011-02-23 11:50:01 (GMT) |
---|---|---|
committer | Olivier Goffart <olivier.goffart@nokia.com> | 2011-02-23 11:50:01 (GMT) |
commit | 5a2f7b97d564e4b8a9619cd7aa1519b4dd084ae8 (patch) | |
tree | 7886477c9d38d8c07008e12abf2eb6e05ed672e3 /src/gui/painting/qpaintengine_raster.cpp | |
parent | ca7be48b7a150952a9657d1000941fb986e5bb2b (diff) | |
parent | 33f0f832a243ee2cb188fcf27126bde6c6c883b0 (diff) | |
download | Qt-5a2f7b97d564e4b8a9619cd7aa1519b4dd084ae8.zip Qt-5a2f7b97d564e4b8a9619cd7aa1519b4dd084ae8.tar.gz Qt-5a2f7b97d564e4b8a9619cd7aa1519b4dd084ae8.tar.bz2 |
Merge remote-tracking branch 'origin/4.7' into qt-master-from-4.7
Conflicts:
src/gui/kernel/qcocoaview_mac.mm
src/s60installs/bwins/QtGuiu.def
src/s60installs/eabi/QtGuiu.def
src/testlib/qtestcase.cpp
Diffstat (limited to 'src/gui/painting/qpaintengine_raster.cpp')
-rw-r--r-- | src/gui/painting/qpaintengine_raster.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gui/painting/qpaintengine_raster.cpp b/src/gui/painting/qpaintengine_raster.cpp index 5513010..9242fb6 100644 --- a/src/gui/painting/qpaintengine_raster.cpp +++ b/src/gui/painting/qpaintengine_raster.cpp @@ -3716,6 +3716,13 @@ void QRasterPaintEnginePrivate::rasterizeLine_dashed(QLineF line, const bool squareCap = (pen.capStyle() == Qt::SquareCap); const QVector<qreal> pattern = pen.dashPattern(); + qreal patternLength = 0; + for (int i = 0; i < pattern.size(); ++i) + patternLength += pattern.at(i); + + if (patternLength <= 0) + return; + qreal length = line.length(); Q_ASSERT(length > 0); while (length > 0) { |