[1/2] gdiplus: GdipCloneFont
Nikolay Sivov
bunglehead at gmail.com
Tue Apr 22 16:12:59 CDT 2008
Changelog:
- implemented GdipCloneFont
---
dlls/gdiplus/font.c | 13 +++++++++++++
dlls/gdiplus/gdiplus.spec | 2 +-
include/gdiplusflat.h | 1 +
3 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/dlls/gdiplus/font.c b/dlls/gdiplus/font.c
index be60843..f458185 100644
--- a/dlls/gdiplus/font.c
+++ b/dlls/gdiplus/font.c
@@ -99,3 +99,16 @@ GpStatus WINGDIPAPI GdipGetLogFontW(GpFont *font, GpGraphics *graphics,
return Ok;
}
+
+GpStatus WINGDIPAPI GdipCloneFont(GpFont *font, GpFont **cloneFont)
+{
+ if(!font || !cloneFont)
+ return InvalidParameter;
+
+ *cloneFont = GdipAlloc(sizeof(GpFont));
+ if(!*cloneFont) return OutOfMemory;
+
+ **cloneFont = *font;
+
+ return Ok;
+}
diff --git a/dlls/gdiplus/gdiplus.spec b/dlls/gdiplus/gdiplus.spec
index cbea1b9..e301f57 100644
--- a/dlls/gdiplus/gdiplus.spec
+++ b/dlls/gdiplus/gdiplus.spec
@@ -50,7 +50,7 @@
@ stub GdipCloneBitmapAreaI
@ stdcall GdipCloneBrush(ptr ptr)
@ stdcall GdipCloneCustomLineCap(ptr ptr)
-@ stub GdipCloneFont
+@ stdcall GdipCloneFont(ptr ptr)
@ stub GdipCloneFontFamily
@ stub GdipCloneImage
@ stub GdipCloneImageAttributes
diff --git a/include/gdiplusflat.h b/include/gdiplusflat.h
index a8f6568..5765795 100644
--- a/include/gdiplusflat.h
+++ b/include/gdiplusflat.h
@@ -313,6 +313,7 @@ GpStatus WINGDIPAPI GdipCreateFontFromLogfontA(HDC,GDIPCONST LOGFONTA*,GpFont**)
GpStatus WINGDIPAPI GdipCreateFontFromLogfontW(HDC,GDIPCONST LOGFONTW*,GpFont**);
GpStatus WINGDIPAPI GdipDeleteFont(GpFont*);
GpStatus WINGDIPAPI GdipGetLogFontW(GpFont*,GpGraphics*,LOGFONTW*);
+GpStatus WINGDIPAPI GdipCloneFont(GpFont*,GpFont**);
GpStatus WINGDIPAPI GdipCreateStringFormat(INT,LANGID,GpStringFormat**);
GpStatus WINGDIPAPI GdipDeleteStringFormat(GpStringFormat*);
--
1.4.4.4
More information about the wine-patches
mailing list