[1/5] gdiplus: Test that clip region doesn't account for gdi32 transform changes.

Vincent Povirk vincent at codeweavers.com
Wed Aug 30 12:32:13 CDT 2017


Signed-off-by: Vincent Povirk <vincent at codeweavers.com>
---
 dlls/gdiplus/tests/graphics.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/dlls/gdiplus/tests/graphics.c b/dlls/gdiplus/tests/graphics.c
index 74d85d1..04e2f50 100644
--- a/dlls/gdiplus/tests/graphics.c
+++ b/dlls/gdiplus/tests/graphics.c
@@ -4959,6 +4959,16 @@ static void test_clipping(void)
     ok(rect.X == 100.0 && rect.Y == 100.0 && rect.Width == 100.0 && rect.Height == 100.0,
        "expected 100.0,100.0-100.0,100.0, got %.2f,%.2f-%.2f,%.2f\n", rect.X, rect.Y, rect.Width, rect.Height);
 
+    /* Clip region does not account for changes to gdi32 transform */
+    SetViewportOrgEx(hdc, 10, 10, NULL);
+
+    status = GdipGetClipBounds(graphics, &rect);
+    expect(Ok, status);
+    ok(rect.X == 100.0 && rect.Y == 100.0 && rect.Width == 100.0 && rect.Height == 100.0,
+       "expected 100.0,100.0-100.0,100.0, got %.2f,%.2f-%.2f,%.2f\n", rect.X, rect.Y, rect.Width, rect.Height);
+
+    SetViewportOrgEx(hdc, 0, 0, NULL);
+
     status = GdipSetEmpty(region);
     expect(Ok, status);
     status = GdipGetClip(graphics, region);
-- 
2.7.4




More information about the wine-patches mailing list