[PATCH] gdi32: fix PatBlt() drawing with negative width/height

Huw Davies huw at codeweavers.com
Fri Nov 20 05:18:58 CST 2020


On Sat, Nov 14, 2020 at 11:56:57AM +0200, Damjan Jovanovic wrote:
> diff --git a/dlls/gdi32/tests/bitmap.c b/dlls/gdi32/tests/bitmap.c
> index fe3482671b2..a3969cf25d6 100644
> --- a/dlls/gdi32/tests/bitmap.c
> +++ b/dlls/gdi32/tests/bitmap.c
> @@ -3074,6 +3074,41 @@ static void test_BitBlt(void)
>      DeleteDC(hdcScreen);
>  }

Hi Damjan,

The tests would be better in tests/dib.c, see under
    /* solid brush PatBlt */
in draw_graphics().  You could add additional PatBlt()s
to the right of the existing one (the dib is 512 pixels
wide).

This also begs the question what happens if the brush
is patterned - is it flipped?  You could add a test
for that under
    /* 8888 DIB pattern brush */
(no need to explore every brush format, just one would
be enough).

Huw.



More information about the wine-devel mailing list