From 049b0a349d1b6ce3053b532ddc26db3db4e99edf Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Wed, 11 Jul 2012 14:05:36 +0000 Subject: [PATCH] Evas font: Fixed runtime emboldenment of bitmap fonts. SVN revision: 73578 --- legacy/evas/ChangeLog | 3 +++ legacy/evas/src/bin/evas_cserve2_fonts.c | 4 +--- legacy/evas/src/lib/engines/common/evas_font_main.c | 3 +-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/legacy/evas/ChangeLog b/legacy/evas/ChangeLog index 4057166a86..8618a8112e 100644 --- a/legacy/evas/ChangeLog +++ b/legacy/evas/ChangeLog @@ -877,3 +877,6 @@ * Let Draw Text with viewport size instead of window size. When map is enabled then it should be rendered completely. +2012-07-11 Tom Hacohen (TAsn) + + * Fixed runtime emboldenment with bitmap fonts. diff --git a/legacy/evas/src/bin/evas_cserve2_fonts.c b/legacy/evas/src/bin/evas_cserve2_fonts.c index 08ed4ae1fd..ce9392283b 100644 --- a/legacy/evas/src/bin/evas_cserve2_fonts.c +++ b/legacy/evas/src/bin/evas_cserve2_fonts.c @@ -314,9 +314,7 @@ _font_slave_glyph_load(Font_Info *fi, unsigned int idx, unsigned int hint) FT_Outline_Transform(&fsi->face->glyph->outline, &transform); /* Embolden the outline of Glyph according to rundtime_rend. */ if (fi->runtime_rend & FONT_REND_WEIGHT) - FT_Outline_Embolden(&fsi->face->glyph->outline, - (fsi->face->size->metrics.x_ppem * 5 * 64) / - 100); + FT_GlyphSlot_Embolden(fsi->face->glyph); return EINA_TRUE; } diff --git a/legacy/evas/src/lib/engines/common/evas_font_main.c b/legacy/evas/src/lib/engines/common/evas_font_main.c index 1977337872..4f271e0dc2 100644 --- a/legacy/evas/src/lib/engines/common/evas_font_main.c +++ b/legacy/evas/src/lib/engines/common/evas_font_main.c @@ -422,8 +422,7 @@ evas_common_font_int_cache_glyph_get(RGBA_Font_Int *fi, FT_UInt idx) FT_Outline_Transform(&fi->src->ft.face->glyph->outline, &transform); /* Embolden the outline of Glyph according to rundtime_rend. */ if (fi->runtime_rend & FONT_REND_WEIGHT) - FT_Outline_Embolden(&fi->src->ft.face->glyph->outline, - (fi->src->ft.face->size->metrics.x_ppem * 5 * 64) / 100); + FT_GlyphSlot_Embolden(fi->src->ft.face->glyph); fg = malloc(sizeof(struct _RGBA_Font_Glyph)); if (!fg) return NULL;