Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.12.3, 5.15.5
-
-
c31638f16b1fe709dd9df232afb9ab7fac3b231e (qt/qtdeclarative/dev) 9a967bf6a6583099d5593e95e29118139f8be975 (qt/qtdeclarative/6.1) 5fde06d4b7113408cb1edc9a2ca4d8aa5a9884af (qt/qtdeclarative/6.2) 1ec362aa10 (qt/tqtc-qtdeclarative/5.15-opensource)
Description
Reset line dash pattern not working in Canvas
import QtQuick 2.12 import QtQuick.Window 2.12 Window { width: 640 height: 480 visible: true Canvas { anchors.fill: parent onPaint: { var ctx = getContext("2d") ctx.lineWidth = 3 ctx.save() ctx.setLineDash([3, 5]) ctx.beginPath() ctx.moveTo(0, 0) ctx.lineTo(250, 250) ctx.stroke() ctx.restore() ctx.save() ctx.setLineDash([]) //no effect ctx.beginPath() ctx.moveTo(50, 0) ctx.lineTo(300, 250) ctx.stroke() ctx.restore() } } }
Attachments
For Gerrit Dashboard: QTBUG-75553 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
260466,3 | QPen::setDashPattern(): don't return early if pattern is empty | 5.15 | qt/qtbase | Status: ABANDONED | -1 | 0 |
359541,3 | When setting the line dash to be an empty array reset the style to Solid | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
359624,2 | When setting the line dash to be an empty array reset the style to Solid | 6.1 | qt/qtdeclarative | Status: MERGED | +2 | 0 |
359625,2 | When setting the line dash to be an empty array reset the style to Solid | 6.2 | qt/qtdeclarative | Status: MERGED | +2 | 0 |
359626,2 | When setting the line dash to be an empty array reset the style to Solid | tqtc/lts-5.15 | qt/tqtc-qtdeclarative | Status: MERGED | +2 | 0 |