2 # include "elementary_config.h"
4 #include <Elementary.h>
5 #ifndef ELM_LIB_QUICKLAUNCH
7 test_separator(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
9 Evas_Object *win, *bx0, *bx, *bt, *sp;
11 win = elm_win_util_standard_add("separators", "Separators");
12 elm_win_autodel_set(win, EINA_TRUE);
14 bx0 = elm_box_add(win);
15 evas_object_size_hint_weight_set(bx0, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
16 elm_box_horizontal_set(bx0, EINA_TRUE);
17 elm_win_resize_object_add(win, bx0);
18 evas_object_show(bx0);
20 bx = elm_box_add(win);
21 evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
22 elm_box_pack_end(bx0, bx);
25 bt = elm_button_add(win);
26 elm_object_text_set(bt, "Left upper corner");
27 elm_box_pack_end(bx, bt);
30 sp = elm_separator_add(win);
31 elm_separator_horizontal_set(sp, EINA_TRUE); // by default, separator is vertical, we must set it horizontal
32 elm_box_pack_end(bx, sp);
35 bt = elm_button_add(win);
36 elm_object_text_set(bt, "Left lower corner");
37 elm_object_disabled_set(bt, EINA_TRUE);
38 elm_box_pack_end(bx, bt);
41 sp = elm_separator_add(win); // now we need vertical separator
42 elm_box_pack_end(bx0, sp);
45 bx = elm_box_add(win);
46 evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
47 elm_box_pack_end(bx0, bx);
50 bt = elm_button_add(win);
51 elm_object_text_set(bt, "Right upper corner");
52 elm_object_disabled_set(bt, EINA_TRUE);
53 elm_box_pack_end(bx, bt);
56 sp = elm_separator_add(win);
57 elm_separator_horizontal_set(sp, EINA_TRUE);
58 elm_box_pack_end(bx, sp);
61 bt = elm_button_add(win);
62 elm_object_text_set(bt, "Right lower corner");
63 elm_box_pack_end(bx, bt);
66 evas_object_show(win);