Module: wine Branch: master Commit: 0c777a7d5cab90ab59d7a4a6b60c516efa7a9830 URL: https://gitlab.winehq.org/wine/wine/-/commit/0c777a7d5cab90ab59d7a4a6b60c516...
Author: Jeff Smith whydoubt@gmail.com Date: Tue Sep 12 03:35:20 2023 -0500
gdiplus: GdipIsVisiblePathPoint is not affected by world transform.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=38823
---
dlls/gdiplus/graphicspath.c | 2 +- dlls/gdiplus/tests/graphicspath.c | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/dlls/gdiplus/graphicspath.c b/dlls/gdiplus/graphicspath.c index fd2622daf0e..8e436f96f4e 100644 --- a/dlls/gdiplus/graphicspath.c +++ b/dlls/gdiplus/graphicspath.c @@ -1793,7 +1793,7 @@ GpStatus WINGDIPAPI GdipIsVisiblePathPoint(GpPath* path, REAL x, REAL y, GpGraph if(status != Ok) return status;
- status = GdipGetRegionHRgn(region, graphics, &hrgn); + status = GdipGetRegionHRgn(region, NULL, &hrgn); if(status != Ok){ GdipDeleteRegion(region); return status; diff --git a/dlls/gdiplus/tests/graphicspath.c b/dlls/gdiplus/tests/graphicspath.c index b0ee9f41360..908ca8bcaf0 100644 --- a/dlls/gdiplus/tests/graphicspath.c +++ b/dlls/gdiplus/tests/graphicspath.c @@ -1865,6 +1865,18 @@ static void test_isvisible(void) status = GdipIsVisiblePathPoint(path, 0.0, 0.0, graphics, &result); expect(Ok, status); expect(TRUE, result); + /* not affected by world transform */ + status = GdipScaleWorldTransform(graphics, 2.0, 2.0, MatrixOrderPrepend); + expect(Ok, status); + result = FALSE; + status = GdipIsVisiblePathPoint(path, 9.0, 9.0, graphics, &result); + expect(Ok, status); + expect(TRUE, result); + result = TRUE; + status = GdipIsVisiblePathPoint(path, 11.0, 11.0, graphics, &result); + expect(Ok, status); + expect(FALSE, result); + GdipResetWorldTransform(graphics);
GdipDeletePath(path); GdipDeleteGraphics(graphics);