tasn pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=2ab088aeea4a306899f442a2aba8fcea63c951dc
commit 2ab088aeea4a306899f442a2aba8fcea63c951dc Author: Tom Hacohen <t...@stosb.com> Date: Fri Sep 20 17:59:44 2013 +0100 Evas textblock: Fixed native size calculation. --- src/lib/evas/canvas/evas_object_textblock.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/src/lib/evas/canvas/evas_object_textblock.c b/src/lib/evas/canvas/evas_object_textblock.c index 376647a..13944fa 100644 --- a/src/lib/evas/canvas/evas_object_textblock.c +++ b/src/lib/evas/canvas/evas_object_textblock.c @@ -10355,8 +10355,16 @@ _size_native_calc_line_finalize(const Evas_Object *eo_obj, Eina_List *items, } else { + Evas_Coord maxasc = 0, maxdesc = 0; _layout_item_ascent_descent_adjust(eo_obj, ascent, descent, it, it->format); + _layout_item_max_ascent_descent_calc(eo_obj, &maxasc, &maxdesc, + it, position); + + if (maxasc > *ascent) + *ascent = maxasc; + if (maxdesc > *descent) + *descent = maxdesc; } loop_advance: @@ -10420,10 +10428,16 @@ _size_native_calc_paragraph_size(const Evas_Object *eo_obj, } } - *position = (*position == TEXTBLOCK_POSITION_START) ? - TEXTBLOCK_POSITION_SINGLE : TEXTBLOCK_POSITION_END; + if (!EINA_INLIST_GET(par)->next) + { + *position = (*position == TEXTBLOCK_POSITION_START) ? + TEXTBLOCK_POSITION_SINGLE : TEXTBLOCK_POSITION_END; + } _size_native_calc_line_finalize(eo_obj, line_items, &ascent, &descent, &w, *position); + if (*position == TEXTBLOCK_POSITION_START) + *position = TEXTBLOCK_POSITION_ELSE; + line_items = eina_list_free(line_items); /* Do the last addition */ --