From 7ab04abf27464ddea69a68cc521a4c93681c6a7d Mon Sep 17 00:00:00 2001 From: subhransu mohanty Date: Tue, 13 Aug 2019 11:17:28 +0900 Subject: [PATCH] edje/style: Remove redundant style tags from style text. Summary: Both font and font_size are already added into the style text in _edje_format_reparse() function and there we update the tag->font_size as well as tag->font member. so I think it is unnecessary to add again which has memory as well as parsing performance impact. Note : someone please update this cryptic comment /* Add font name last to save evas from multiple loads */ how this is going to help saving multiple load. Reviewers: ali.alzyod, Hermet, raster, cedric Reviewed By: Hermet Subscribers: segfaultxavi, cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9543 --- src/lib/edje/edje_textblock_styles.c | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/lib/edje/edje_textblock_styles.c b/src/lib/edje/edje_textblock_styles.c index 1b7e94b6a1..e83a21d227 100644 --- a/src/lib/edje/edje_textblock_styles.c +++ b/src/lib/edje/edje_textblock_styles.c @@ -515,22 +515,6 @@ _edje_textblock_style_parse_and_fix(Edje_File *edf) eina_strbuf_append(txt, fontsource); } } - if (tag->font_size > 0) - { - char font_size[32]; - - snprintf(font_size, sizeof(font_size), "%f", tag->font_size); - eina_strbuf_append(txt, " "); - eina_strbuf_append(txt, "font_size="); - eina_strbuf_append(txt, font_size); - } - /* Add font name last to save evas from multiple loads */ - if (tag->font) - { - eina_strbuf_append(txt, " "); - eina_strbuf_append(txt, "font="); - eina_strbuf_append_escaped(txt, tag->font); - } eina_strbuf_append(txt, "'"); } if (fontset) free(fontset);