Evan Stade : gdiplus: Added GdipClosePathFigures.
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Jul 9 10:25:00 CDT 2007
Module: wine
Branch: master
Commit: d0ba8711ff24ee59df9d87423ddb5b85f8c93186
URL: http://source.winehq.org/git/wine.git/?a=commit;h=d0ba8711ff24ee59df9d87423ddb5b85f8c93186
Author: Evan Stade <estade at gmail.com>
Date: Fri Jul 6 16:14:24 2007 -0700
gdiplus: Added GdipClosePathFigures.
---
dlls/gdiplus/gdiplus.spec | 2 +-
dlls/gdiplus/graphicspath.c | 17 +++++++++++++++++
include/gdiplusflat.h | 1 +
3 files changed, 19 insertions(+), 1 deletions(-)
diff --git a/dlls/gdiplus/gdiplus.spec b/dlls/gdiplus/gdiplus.spec
index 8b665fc..1cabb0a 100644
--- a/dlls/gdiplus/gdiplus.spec
+++ b/dlls/gdiplus/gdiplus.spec
@@ -55,7 +55,7 @@
@ stub GdipCloneRegion
@ stub GdipCloneStringFormat
@ stdcall GdipClosePathFigure(ptr)
-@ stub GdipClosePathFigures
+@ stdcall GdipClosePathFigures(ptr)
@ stub GdipCombineRegionPath
@ stub GdipCombineRegionRect
@ stub GdipCombineRegionRectI
diff --git a/dlls/gdiplus/graphicspath.c b/dlls/gdiplus/graphicspath.c
index c06576c..24bc7d9 100644
--- a/dlls/gdiplus/graphicspath.c
+++ b/dlls/gdiplus/graphicspath.c
@@ -103,6 +103,23 @@ GpStatus WINGDIPAPI GdipClosePathFigure(GpPath* path)
return Ok;
}
+GpStatus WINGDIPAPI GdipClosePathFigures(GpPath* path)
+{
+ INT i;
+
+ if(!path)
+ return InvalidParameter;
+
+ for(i = 1; i < path->pathdata.Count; i++){
+ if(path->pathdata.Types[i] == PathPointTypeStart)
+ path->pathdata.Types[i-1] |= PathPointTypeCloseSubpath;
+ }
+
+ path->newfigure = TRUE;
+
+ return Ok;
+}
+
GpStatus WINGDIPAPI GdipCreatePath(GpFillMode fill, GpPath **path)
{
if(!path)
diff --git a/include/gdiplusflat.h b/include/gdiplusflat.h
index 3546883..6d3da28 100644
--- a/include/gdiplusflat.h
+++ b/include/gdiplusflat.h
@@ -50,6 +50,7 @@ GpStatus WINGDIPAPI GdipDeleteBrush(GpBrush*);
GpStatus WINGDIPAPI GdipAddPathLine2(GpPath*,GDIPCONST GpPointF*,INT);
GpStatus WINGDIPAPI GdipClosePathFigure(GpPath*);
+GpStatus WINGDIPAPI GdipClosePathFigures(GpPath*);
GpStatus WINGDIPAPI GdipCreatePath(GpFillMode,GpPath**);
GpStatus WINGDIPAPI GdipDeletePath(GpPath*);
More information about the wine-cvs
mailing list