Commit cb21d1ca authored by Vincent Povirk's avatar Vincent Povirk Committed by Alexandre Julliard

gdiplus: Don't rely on an HDC in GdipGetFontHeight.

parent 4fff9a7a
......@@ -452,12 +452,16 @@ GpStatus WINGDIPAPI GdipGetFontHeight(GDIPCONST GpFont *font,
GDIPCONST GpGraphics *graphics, REAL *height)
{
REAL dpi;
GpStatus stat;
TRACE("%p %p %p\n", font, graphics, height);
dpi = GetDeviceCaps(graphics->hdc, LOGPIXELSY);
stat = GdipGetDpiY((GpGraphics*)graphics, &dpi);
if (stat == Ok)
stat = GdipGetFontHeightGivenDPI(font, dpi, height);
return GdipGetFontHeightGivenDPI(font, dpi, height);
return stat;
}
/*******************************************************************************
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment