gdiplus: Implement GdipGetFontUnit.

This commit is contained in:
Adam Petaccia 2008-06-21 13:02:54 -04:00 committed by Alexandre Julliard
parent b0b1588ab6
commit 1919b124a2
3 changed files with 22 additions and 1 deletions

View File

@ -236,6 +236,26 @@ GpStatus WINGDIPAPI GdipCreateFontFromDC(HDC hdc, GpFont **font)
return GdipCreateFontFromLogfontW(hdc, &lfw, font);
}
/*******************************************************************************
* GdipGetFontUnit [GDIPLUS.@]
*
* PARAMS
* font [I] Font to retrieve from
* unit [O] Return value
*
* RETURNS
* FAILURE: font or unit was NULL
* OK: otherwise
*/
GpStatus WINGDIPAPI GdipGetFontUnit(GpFont *font, Unit *unit)
{
if (!(font && unit)) return InvalidParameter;
*unit = font->unit;
return Ok;
}
/* FIXME: use graphics */
GpStatus WINGDIPAPI GdipGetLogFontW(GpFont *font, GpGraphics *graphics,
LOGFONTW *lfw)

View File

@ -271,7 +271,7 @@
@ stub GdipGetFontHeightGivenDPI
@ stub GdipGetFontSize
@ stub GdipGetFontStyle
@ stub GdipGetFontUnit
@ stdcall GdipGetFontUnit(ptr ptr)
@ stdcall GdipGetGenericFontFamilyMonospace(ptr)
@ stdcall GdipGetGenericFontFamilySansSerif(ptr)
@ stdcall GdipGetGenericFontFamilySerif(ptr)

View File

@ -349,6 +349,7 @@ GpStatus WINGDIPAPI GdipCreateFontFromLogfontW(HDC,GDIPCONST LOGFONTW*,GpFont**)
GpStatus WINGDIPAPI GdipDeleteFont(GpFont*);
GpStatus WINGDIPAPI GdipGetLogFontW(GpFont*,GpGraphics*,LOGFONTW*);
GpStatus WINGDIPAPI GdipCloneFont(GpFont*,GpFont**);
GpStatus WINGDIPAPI GdipGetFontUnit(GpFont*, Unit*);
GpStatus WINGDIPAPI GdipCreateFontFamilyFromName(GDIPCONST WCHAR*,
GpFontCollection*, GpFontFamily**);