From 2be301dabccb926b71580b8bfaccce970ad6efbb Mon Sep 17 00:00:00 2001 From: tasn Date: Sun, 17 Jun 2012 07:18:50 +0000 Subject: [PATCH] Evas font: Fix the font engine to work with Bitmap fonts. Oops, I used the Outline CBox function instead of the Glyph one. Fixed. git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@72278 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- src/lib/engines/common/evas_font_main.c | 3 ++- src/lib/engines/common/evas_text_utils.c | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/engines/common/evas_font_main.c b/src/lib/engines/common/evas_font_main.c index 06e0f9d..10f0d7a 100644 --- a/src/lib/engines/common/evas_font_main.c +++ b/src/lib/engines/common/evas_font_main.c @@ -404,7 +404,8 @@ evas_common_font_int_cache_glyph_get(RGBA_Font_Int *fi, FT_UInt idx) { FT_BBox outbox; - FT_Outline_Get_CBox(&fi->src->ft.face->glyph->outline, &outbox); + FT_Glyph_Get_CBox(fg->glyph, FT_GLYPH_BBOX_UNSCALED, + &outbox); fg->width = EVAS_FONT_ROUND_26_6_TO_INT(outbox.xMax - outbox.xMin); fg->x_bear = EVAS_FONT_ROUND_26_6_TO_INT(outbox.xMin); } diff --git a/src/lib/engines/common/evas_text_utils.c b/src/lib/engines/common/evas_text_utils.c index 1cdcacd..b2e291e 100644 --- a/src/lib/engines/common/evas_text_utils.c +++ b/src/lib/engines/common/evas_text_utils.c @@ -502,3 +502,4 @@ evas_common_text_props_content_create(void *_fi, const Eina_Unicode *text, text_props->info->refcount = 1; return EINA_TRUE; } + -- 2.7.4