[coretext] Move font size to a macro

This commit is contained in:
Behdad Esfahbod 2017-10-11 12:51:25 +02:00
parent 8d450dd188
commit f9b4c6570a
1 changed files with 2 additions and 1 deletions

View File

@ -36,6 +36,7 @@
#define HB_DEBUG_CORETEXT (HB_DEBUG+0) #define HB_DEBUG_CORETEXT (HB_DEBUG+0)
#endif #endif
#define HB_CORETEXT_FONT_SIZE 18.0
static void static void
release_table_data (void *user_data) release_table_data (void *user_data)
@ -229,7 +230,7 @@ _hb_coretext_shaper_face_data_create (hb_face_t *face)
* Since we always create CTFont at a fixed size, our CTFont lives in face_data * Since we always create CTFont at a fixed size, our CTFont lives in face_data
* instead of font_data. Which is good, because when people change scale on * instead of font_data. Which is good, because when people change scale on
* hb_font_t, we won't need to update our CTFont. */ * hb_font_t, we won't need to update our CTFont. */
data->ct_font = create_ct_font (data->cg_font, 18.); data->ct_font = create_ct_font (data->cg_font, HB_CORETEXT_FONT_SIZE);
if (unlikely (!data->ct_font)) if (unlikely (!data->ct_font))
{ {
DEBUG_MSG (CORETEXT, face, "CTFont creation failed."); DEBUG_MSG (CORETEXT, face, "CTFont creation failed.");