Akihiro Sagawa : gdi32: Move otmEMSquare initialization to freetype_load_font.

Alexandre Julliard julliard at winehq.org
Wed Apr 7 15:48:31 CDT 2021


Module: wine
Branch: master
Commit: 8f6f1c8f7aa2b848f0ebb15ec9e2b03854caf710
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=8f6f1c8f7aa2b848f0ebb15ec9e2b03854caf710

Author: Akihiro Sagawa <sagawa.aki at gmail.com>
Date:   Tue Apr  6 21:34:19 2021 +0900

gdi32: Move otmEMSquare initialization to freetype_load_font.

Signed-off-by: Akihiro Sagawa <sagawa.aki at gmail.com>
Signed-off-by: Huw Davies <huw at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/gdi32/freetype.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/gdi32/freetype.c b/dlls/gdi32/freetype.c
index 2535faad03a..c66db289ab1 100644
--- a/dlls/gdi32/freetype.c
+++ b/dlls/gdi32/freetype.c
@@ -2496,6 +2496,7 @@ static BOOL CDECL freetype_load_font( struct gdi_font *font )
         TRACE( "height %d => ppem %d\n", font->lf.lfHeight, font->ppem );
         height = font->ppem;
         font->ttc_item_offset = get_ttc_offset( ft_face, font->face_index );
+        font->otm.otmEMSquare = ft_face->units_per_EM;
     }
     else
     {
@@ -3946,7 +3947,6 @@ static BOOL CDECL freetype_set_outline_text_metrics( struct gdi_font *font )
     font->otm.otmsCharSlopeRise = pHori->caret_Slope_Rise;
     font->otm.otmsCharSlopeRun = pHori->caret_Slope_Run;
     font->otm.otmItalicAngle = 0; /* POST table */
-    font->otm.otmEMSquare = ft_face->units_per_EM;
     font->otm.otmAscent = SCALE_Y(pOS2->sTypoAscender);
     font->otm.otmDescent = SCALE_Y(pOS2->sTypoDescender);
     font->otm.otmLineGap = SCALE_Y(pOS2->sTypoLineGap);




More information about the wine-cvs mailing list