evas: Fix Evas Object Text when LTR and RTL are used together.

When harfbuzz is enabled, RTL text (arabic, hebrew...) is displayed differently
if the paragraph begins with or without LTR.
The problem was related to the function evas_common_language_script_type_get
and a wrong offset given as parameter to this function.

Thanks to EunYoung Kim for having found this bug.

Signed-off-by: Daniel Zaoui <daniel.zaoui@samsung.com>
This commit is contained in:
Daniel Zaoui 2013-02-19 08:55:40 +02:00
parent 91711d8a69
commit aa488588d8
3 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2013-02-19 Daniel Zaoui
* Fix Evas_Object_Text when LTR and RTL are used in the same paragraph.
2013-02-18 Carsten Haitzler (The Rasterman)
* Fix edje edje_color_class_list() and edje_text_class_list() to

1
NEWS
View File

@ -174,3 +174,4 @@ Fixes:
* Edje textblock: Improved textblock fit.
* fix anchor clicked mouse signals for selection-enabled entries
* Fix edje_color_class_list() and edje_text_class_list() to look at right hashes.
* Evas: Fix Evas_Object_Text when LTR and RTL are used in the same paragraph.

View File

@ -722,7 +722,7 @@ _evas_object_text_layout(Evas_Object *eo_obj, Evas_Object_Text *o, Eina_Unicode
if (tmp_cut > 0)
script_len = tmp_cut;
script = evas_common_language_script_type_get(text, script_len);
script = evas_common_language_script_type_get(text + pos, script_len);
while (script_len > 0)
{