From bc70a1bd84dec728d2b9d417b4a3c92aecddeb75 Mon Sep 17 00:00:00 2001 From: Youngbok Shin Date: Wed, 21 May 2014 10:39:36 +0100 Subject: [PATCH] evas/text: fix abnormal ellipsis logic when harfbuzz is enabled. Summary: text_props.len indicates visual length from harfbuzz logic when it is available. But, input pram "idx" is logical length. So, ellipsis works abnormally in some case. @fix Test Plan: D870 Reviewers: tasn, woohyun CC: cedric, herdsman Differential Revision: https://phab.enlightenment.org/D871 --- src/lib/evas/canvas/evas_object_text.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/evas/canvas/evas_object_text.c b/src/lib/evas/canvas/evas_object_text.c index 8e960da59d..8ddfdd9b07 100644 --- a/src/lib/evas/canvas/evas_object_text.c +++ b/src/lib/evas/canvas/evas_object_text.c @@ -636,7 +636,7 @@ static Eina_Bool _layout_text_item_trim(Evas_Object_Protected_Data *obj, Evas_Text_Data *o, Evas_Object_Text_Item *ti, int idx, Eina_Bool want_start) { Evas_Text_Props new_text_props; - if (idx >= (int) ti->text_props.len) + if (idx >= (int) ti->text_props.text_len) return EINA_FALSE; memset(&new_text_props, 0, sizeof (new_text_props));