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