When using the cosmetic stroker (i.e. plain pens with effective line width of 1), drawing points with fractional coordinates >= 0.5 would fill the wrong pixel. This is a long-standing bug where the drawPoints() code in the cosmetic stroker code was missed during the painting coordinate system shift for Qt 5.0. Prior to that, coordinates were interpreted as the upper left corner of a pixel, so rounding fractional coordinates to the closest integer would be the correct way to determine the pixel to be filled. From Qt 5 onwards however, coordinates instead designate the center point of the primitive to be stroked. In order to determine which pixel is most covered by the unit square centered in the given coordinates, fractional coordinates must be rounded downwards (floored). This fix makes the behavior consistent between the cosmetic and non-cosmetic stroker, so that drawPoints() with e.g. penwidths 1 and 1.01 in practice fills the same pixels. Pick-to: 6.6 Fixes: QTBUG-119306 Change-Id: I39cb7ad55229553dda098e6fbc9ee449b1fd9664 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> |
||
|---|---|---|
| .. | ||
| auto | ||
| baseline | ||
| benchmarks | ||
| global | ||
| libfuzzer | ||
| manual | ||
| shared | ||
| testserver | ||
| CMakeLists.txt | ||
| README | ||
README
This directory contains autotests and benchmarks based on Qt Test. In order
to run the autotests reliably, you need to configure a desktop to match the
test environment that these tests are written for.
Linux X11:
* The user must be logged in to an active desktop; you can't run the
autotests without a valid DISPLAY that allows X11 connections.
* The tests are run against a KDE3 or KDE4 desktop.
* Window manager uses "click to focus", and not "focus follows mouse". Many
tests move the mouse cursor around and expect this to not affect focus
and activation.
* Disable "click to activate", i.e., when a window is opened, the window
manager should automatically activate it (give it input focus) and not
wait for the user to click the window.