In a (x, y, w, h) rectangle passed to PatBlt(), a negative w results in the rectangle drawn being (x+w, y, -w, h), and negative h results in (x, y+h, w, -h). Wine instead does (x+w+1, y, -w, h) and (x, y+h+1, w, -h), so the rectangle drawn is misplaced:
Windows (0,0) +------+ |+-----++ || || ++-----+| +------+ Wine
This patch recalculates the rectangle dimensions correctly.
Try 2 tests brush patterns and multiple DIB/DDB formats.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=27584 Signed-off-by: Damjan Jovanovic damjan.jov@gmail.com --- dlls/gdi32/bitblt.c | 11 ++++++ dlls/gdi32/tests/dib.c | 86 ++++++++++++++++++++++++------------------ 2 files changed, 61 insertions(+), 36 deletions(-)