evas text: do recalc immediately whenever ellipsis property is changed 25/251625/1 submit/tizen/20210118.100628
authorYoungbok Shin <youngb.shin@samsung.com>
Sat, 16 Jan 2021 07:42:34 +0000 (16:42 +0900)
committerYoungbok Shin <youngb.shin@samsung.com>
Sat, 16 Jan 2021 07:42:34 +0000 (16:42 +0900)
It was impossible to get properly recalculated size immediately when
the ellipsis property is updated. It required some meaningless resize call
to trigger the Evas Text calculation.
So, the patch put the recalc function in evas_object_text_ellipsis_set() function
to do recalc immediately.

Change-Id: I425f27e3fa3c37cebddde60e9e357b7238f5a28f

src/lib/evas/canvas/evas_object_text.c

index 40c0c80..174ed6b 100644 (file)
@@ -1129,6 +1129,7 @@ _evas_text_ellipsis_set(Eo *eo_obj, Evas_Text_Data *o, double ellipsis)
    evas_object_async_block(obj);
    o->prev.ellipsis = o->cur.ellipsis;
    o->cur.ellipsis = ellipsis;
+   _evas_object_text_recalc(eo_obj, o->cur.text);
    o->changed = 1;
    if (o->has_filter)
      evas_filter_changed_set(eo_obj, EINA_TRUE);