From f8747be98455fbb55281b501eea123b7b485c605 Mon Sep 17 00:00:00 2001 From: handa Date: Sat, 20 Aug 2005 02:38:48 +0000 Subject: [PATCH] (ft_open): Set members ascent, descent, and max_advance of rfont. (mfont__ft_parse_name): Add const to the arg name. --- src/font-ft.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/font-ft.c b/src/font-ft.c index 74a8aa4..41b6aab 100644 --- a/src/font-ft.c +++ b/src/font-ft.c @@ -1226,6 +1226,9 @@ ft_open (MFrame *frame, MFont *font, MFont *spec, MRealizedFont *rfont) rfont->driver = &mfont__ft_driver; rfont->info = ft_rfont; rfont->fontp = ft_face; + rfont->ascent = ft_face->size->metrics.ascender >> 6; + rfont->descent = - ft_face->size->metrics.descender >> 6; + rfont->max_advance = ft_face->size->metrics.max_advance >> 6; rfont->next = MPLIST_VAL (frame->realized_font_list); MPLIST_VAL (frame->realized_font_list) = rfont; MDEBUG_PRINT ("ok\n"); @@ -1784,7 +1787,7 @@ mfont__ft_fini () #ifdef HAVE_FONTCONFIG int -mfont__ft_parse_name (char *name, MFont *font) +mfont__ft_parse_name (const char *name, MFont *font) { FcPattern *pat = FcNameParse ((FcChar8 *) name); FcChar8 *str; -- 1.7.10.4