Details
-
Bug
-
Resolution: Duplicate
-
Not Evaluated
-
None
-
5.0.2
-
None
-
Qt 5.1.0
GCC 4.8.0
Windows 8 64bits
Description
This seems to appear only when the width is an odd integer, and in release mode. This issue does not appear when compiled in debug mode.
The raster paint engine is used.
QImage img(200, 200, QImage::Format_ARGB32_Premultiplied);
img.fill(Qt::transparent);
QPainter p(&img);
p.setPen(QPen(QColor(255, 255, 0), 3, Qt::SolidLine, Qt::SquareCap, Qt::BevelJoin));
p.drawLine(50, 50, 100, 50);
img.save("foo.png"); // The line has a width of 2 pixels.
// If the pen had a width of 5 pixels, the line would have had a width of 6 pixels...
Attachments
Issue Links
- is replaced by
-
QTBUG-32387 QPainter::drawLine() results differ from Debug to Release
- Open