summaryrefslogtreecommitdiff
path: root/src/modules/evas/vg_loaders/svg/evas_vg_load_svg.c
diff options
context:
space:
mode:
authorJunsuChoi <jsuya.choi@samsung.com>2019-08-19 19:46:01 +0900
committerHermet Park <hermetpark@gmail.com>2019-08-19 19:46:02 +0900
commit8f440cdedc090fd71fbda4c10bf2f4af6bafec40 (patch)
tree8635887175bbbcd92d79fe8902aac62dd3f2b182 /src/modules/evas/vg_loaders/svg/evas_vg_load_svg.c
parentdafd3dc7b82863c8dbd65105fa53fe612d7a655f (diff)
vg_common_svg: Apply node opacity to stroke color
Summary: When an object to be converted to a stroke or path uses "opacity" attribute, opacity is also applied. Test Plan: [SVG] <?xml version="1.0" encoding="UTF-8"?> <svg width="40px" height="40px" viewBox="0 0 40 40" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <!-- Generator: Sketch 52.6 (67491) - http://www.bohemiancoding.com/sketch --> <rect fill="#FF0000" opacity="0" x="0" y="0" width="40" height="40"></rect> <path d="M12,20 L25,8 L12,20 Z M12,20 L25,32 L12,20 Z" id="Combined-Shape" stroke="#FFFFFF" stroke-width="2" opacity="0.12" stroke-linecap="round" stroke-linejoin="round" fill-rule="nonzero"></path> </svg> [Code] int main(int argc, char **argv) { setenv("ECTOR_BACKEND", "default", 1); elm_init(argc, argv); Evas_Object *win = elm_win_util_standard_add(NULL, "test"); evas_object_smart_callback_add(win, "delete,request", win_del, 0); elm_win_autodel_set(win, 1); Evas *evas = evas_object_evas_get(win); Evas_Object *vg = evas_object_vg_add(evas); evas_object_show(vg); Evas_Object *container = evas_vg_container_add(vg); evas_object_vg_root_node_set(vg, container); Evas_Object *svg = efl_add(EFL_CANVAS_VG_OBJECT_CLASS, container); efl_file_simple_load(svg, "./i_arrow_l_disable.svg", NULL); efl_gfx_entity_size_set(svg, EINA_SIZE2D(600, 600)); efl_gfx_entity_visible_set(svg, EINA_TRUE); evas_object_size_hint_weight_set(svg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_size_hint_align_set(svg, EVAS_HINT_FILL, EVAS_HINT_FILL); elm_win_resize_object_add(win, vg); evas_object_resize(win, 600, 600); evas_object_show(win); elm_run(); elm_shutdown(); return 0; } Reviewers: Hermet, smohanty, kimcinoo Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9620
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions