From 0601a19d38b2b0fc5dd36fd821af634a49322ebf Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 8 May 2019 07:47:36 -0700 Subject: [PATCH] Fix a few more double-pomotion errors --- src/hb-coretext.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/hb-coretext.cc b/src/hb-coretext.cc index e0579be..bf8e96c 100644 --- a/src/hb-coretext.cc +++ b/src/hb-coretext.cc @@ -55,13 +55,13 @@ coretext_font_size_from_ptem (float ptem) * https://developer.apple.com/library/content/documentation/GraphicsAnimation/Conceptual/HighResolutionOSX/Explained/Explained.html */ ptem *= 96.f / 72.f; - return ptem <= 0.f ? HB_CORETEXT_DEFAULT_FONT_SIZE : ptem; + return (CGFloat) (ptem <= 0.f ? HB_CORETEXT_DEFAULT_FONT_SIZE : ptem); } static float coretext_font_size_to_ptem (CGFloat size) { - size *= 72.f / 96.f; - return size <= 0.f ? 0 : size; + size *= 72. / 96.; + return size <= 0 ? 0 : size; } static void -- 2.7.4