forked from enlightenment/efl
Evas font-engine: *text_props_script_set add parameter len.
SVN revision: 58616
This commit is contained in:
parent
1cdcceff91
commit
ffbe4ed971
|
@ -475,7 +475,7 @@ _evas_object_text_item_new(Evas_Object *obj, Evas_Object_Text *o,
|
|||
eina_unicode_strncpy(it->text, str + pos, len);
|
||||
evas_common_text_props_bidi_set(&it->text_props, o->bidi_par_props,
|
||||
it->text_pos);
|
||||
evas_common_text_props_script_set(&it->text_props, it->text);
|
||||
evas_common_text_props_script_set(&it->text_props, it->text, len);
|
||||
if (o->engine_data)
|
||||
{
|
||||
ENFN->font_text_props_info_create(ENDT,
|
||||
|
|
|
@ -2779,7 +2779,7 @@ skip:
|
|||
evas_common_text_props_bidi_set(&ti->text_props,
|
||||
ti->parent.text_node->bidi_props, ti->parent.text_pos);
|
||||
evas_common_text_props_script_set (&ti->text_props,
|
||||
ti->text);
|
||||
ti->text, tmp_len);
|
||||
if (ti->parent.format->font.font)
|
||||
{
|
||||
c->ENFN->font_text_props_info_create(c->ENDT,
|
||||
|
@ -3224,7 +3224,7 @@ _layout_ellipsis_item_new(Ctxt *c, const Evas_Object_Textblock_Item *cur_it)
|
|||
evas_common_text_props_bidi_set(&ellip_ti->text_props,
|
||||
ellip_ti->parent.text_node->bidi_props, ellip_ti->parent.text_pos);
|
||||
evas_common_text_props_script_set (&ellip_ti->text_props,
|
||||
ellip_ti->text);
|
||||
ellip_ti->text, len);
|
||||
c->ENFN->font_text_props_info_create(c->ENDT,
|
||||
ellip_ti->parent.format->font.font,
|
||||
ellip_ti->text, &ellip_ti->text_props,
|
||||
|
|
|
@ -26,9 +26,9 @@ evas_common_text_props_bidi_set(Evas_Text_Props *props,
|
|||
|
||||
void
|
||||
evas_common_text_props_script_set(Evas_Text_Props *props,
|
||||
const Eina_Unicode *str)
|
||||
const Eina_Unicode *str, size_t len)
|
||||
{
|
||||
props->script = evas_common_language_script_type_get(str);
|
||||
props->script = evas_common_language_script_type_get(str, len);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -51,7 +51,7 @@ evas_common_text_props_bidi_set(Evas_Text_Props *props,
|
|||
|
||||
void
|
||||
evas_common_text_props_script_set(Evas_Text_Props *props,
|
||||
const Eina_Unicode *str);
|
||||
const Eina_Unicode *str, size_t len);
|
||||
|
||||
EAPI Eina_Bool
|
||||
evas_common_text_props_content_create(void *_fn, const Eina_Unicode *text,
|
||||
|
|
|
@ -101,11 +101,12 @@ evas_common_language_script_end_of_run_get(const Eina_Unicode *str,
|
|||
}
|
||||
|
||||
Evas_Script_Type
|
||||
evas_common_language_script_type_get(const Eina_Unicode *str)
|
||||
evas_common_language_script_type_get(const Eina_Unicode *str, size_t len)
|
||||
{
|
||||
Evas_Script_Type script = EVAS_SCRIPT_COMMON;
|
||||
const Eina_Unicode *end = str + len;
|
||||
/* Arabic is the first script in the array that's not a common/inherited */
|
||||
for ( ; *str && ((script = evas_common_language_char_script_get(*str)) < EVAS_SCRIPT_ARABIC) ; str++)
|
||||
for ( ; str < end && ((script = evas_common_language_char_script_get(*str)) < EVAS_SCRIPT_ARABIC) ; str++)
|
||||
;
|
||||
return script;
|
||||
}
|
||||
|
|
|
@ -117,7 +117,7 @@ int
|
|||
evas_common_language_script_end_of_run_get(const Eina_Unicode *str, const Evas_BiDi_Paragraph_Props *bidi_props, size_t start, int len);
|
||||
|
||||
Evas_Script_Type
|
||||
evas_common_language_script_type_get(const Eina_Unicode *str);
|
||||
evas_common_language_script_type_get(const Eina_Unicode *str, size_t len);
|
||||
|
||||
Evas_Script_Type
|
||||
evas_common_language_char_script_get(Eina_Unicode unicode);
|
||||
|
|
Loading…
Reference in New Issue