Qt 6.11 is out! See what's new in the release
blog
Drawing a clean line by QGraphicsScene
-
Hi there,
I'm using QGraphicsScene.addLine() to draw some gradient lines. But the drawn lines are not so clear and do not have a flat outline, as the middle one in the picture below, looks like stairs.

While the ideal shape for my usage should be something like picture below.

-
Hi there,
I'm using QGraphicsScene.addLine() to draw some gradient lines. But the drawn lines are not so clear and do not have a flat outline, as the middle one in the picture below, looks like stairs.

While the ideal shape for my usage should be something like picture below.

-
@mfaghani
make its QGraphicsView use antialiasing.
view.setRenderHints(QPainter::Antialiasing);
as described here