Page MenuHomePhabricator

edje: markup flag should be TRUE in legacy edje_object_part_text_set
ClosedPublic

Authored by bowonryu on Thu, May 21, 11:30 PM.

Details

Summary

Through some APIs (elm_entry_editable_set, elm_entry_single_line_set, etc.)
located after edje_object_part_text_set(legacy)

If efl_ui_widget_theme_apply is called,
In edje_object_part_text_raw_generic_set, the legacy flag becomes FALSE.
And in this case, the logic works in the unintended direction
because the set_markup flag is FALSE.

Test Plan

/*
gcc -o entry_example entry.c pkg-config --cflags --libs elementary
*/
#include <Elementary.h>

EAPI_MAIN int
elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
{

Evas_Object *win, *en;

elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);

win = elm_win_util_standard_add("entry-example", "test");
elm_win_autodel_set(win, EINA_TRUE);
en = elm_entry_add(win);
evas_object_size_hint_weight_set(en, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_object_part_text_set(en, "elm.guide", "<font_size=32 color=#FFF>TEST</font_size>");
elm_entry_editable_set(en, EINA_FALSE);

evas_object_show(en);

elm_object_content_set(win, en);
evas_object_resize(win, 300, 200);
evas_object_show(win);

elm_run();

return 0;

}
ELM_MAIN()

Diff Detail

Repository
rEFL core/efl
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
bowonryu created this revision.Thu, May 21, 11:30 PM
bowonryu requested review of this revision.Thu, May 21, 11:30 PM
zmike added a subscriber: zmike.Fri, May 22, 5:44 AM

Can this test code be added as a unit test?

bowonryu updated this revision to Diff 30373.Sun, May 24, 10:22 PM

unit test updated

woohyun accepted this revision.Thu, Jun 4, 10:29 PM

Everything looks good for me including test case. Accepted :)

This revision is now accepted and ready to land.Thu, Jun 4, 10:29 PM
This revision was automatically updated to reflect the committed changes.