Details
-
Bug
-
Resolution: Cannot Reproduce
-
P3: Somewhat important
-
None
-
4.5.1
-
None
Description
t4id: 254216
When two adjacents QPolygonF are painted, there is a space between them. This only happen with the Raster engine.
Here is the code to reproduce the problem:
#include <QtGui> class Widget : public QWidget { public: Widget() { resize(750, 500); } void paintEvent(QPaintEvent* e) { QWidget::paintEvent(e); QPixmap pix(750, 500); QPainter painter(&pix); painter.setPen(Qt::NoPen); painter.setBrush(Qt::white); painter.drawRect(0, 0, 750, 500); QPolygonF array; painter.setBrush(Qt::black); float height = 5.049f; for(float x = 0; x < 750; x += 11) { for(float y = 0; y < 500; y += height) { array.clear(); array << QPointF(x, y); array << QPointF(x + 10, y); array << QPointF(x + 10, y + height); array << QPointF(x, y + height); painter.drawPolygon(array); } height += 0.0013f; } painter.end(); QPainter painter2(this); painter2.drawPixmap(0, 0, pix); } }; int main( int argc, char ** argv ) { QApplication a( argc, argv ); Widget win;; win.show(); return a.exec(); }