Skip to content

QPainter: fix assert when drawing bitmaps at very near to .5 coord

The code assumed that the rounding of a floating point value, and the rounding of the sum of that value and an integer, would always snap in the same direction. But because of accuracy limits (independently of the rounding function employed), that is not always the case for fractions very near to .5.

Fixes: QTBUG-122451 Pick-to: 6.7 6.6 6.5 6.2 5.15 Change-Id: I0825d42e6be7f6e3397760a5e9be5dddca42dcdc Reviewed-by: Eskil Abrahamsen Blomfeldt eskil.abrahamsen-blomfeldt@qt.io Reviewed-by: Qt CI Bot qt_ci_bot@qt-project.org (cherry picked from commit a43d86fe)

Merge request reports