From a5ebe1d4aec41bc5e289a7969e5e5f7bb57733b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20R=C3=B6ttsches?= Date: Wed, 11 Oct 2017 13:32:38 +0200 Subject: [PATCH] [coretext] Recreate CTFont if pt size changed Attempt at fixing #360 --- src/hb-coretext.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/hb-coretext.cc b/src/hb-coretext.cc index 9b680abf6..8219284dc 100644 --- a/src/hb-coretext.cc +++ b/src/hb-coretext.cc @@ -71,8 +71,9 @@ hb_coretext_face_create (CGFontRef cg_font) HB_SHAPER_DATA_ENSURE_DEFINE(coretext, face) -HB_SHAPER_DATA_ENSURE_DEFINE(coretext, font) - +HB_SHAPER_DATA_ENSURE_DEFINE_WITH_CONDITION(coretext, font, + abs (CTFontGetSize((CTFontRef) data) - + (font->ptem < 0 ? HB_CORETEXT_FONT_SIZE : font->ptem)) < 1) /* * shaper face data