aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/elementary/src/examples/calendar_example_01.c
diff options
context:
space:
mode:
authorDavid Walter Seikel2012-04-22 09:20:32 +1000
committerDavid Walter Seikel2012-04-22 09:20:32 +1000
commit3ad3455551be0d7859ecb02290376206d5e66498 (patch)
tree497917e12b4d7f458dff9765d9b53f64c4e03fc3 /libraries/elementary/src/examples/calendar_example_01.c
parentUpdate EFL to latest beta. (diff)
downloadSledjHamr-3ad3455551be0d7859ecb02290376206d5e66498.zip
SledjHamr-3ad3455551be0d7859ecb02290376206d5e66498.tar.gz
SledjHamr-3ad3455551be0d7859ecb02290376206d5e66498.tar.bz2
SledjHamr-3ad3455551be0d7859ecb02290376206d5e66498.tar.xz
And actually include new files, plus elementary libraries.
Diffstat (limited to 'libraries/elementary/src/examples/calendar_example_01.c')
-rw-r--r--libraries/elementary/src/examples/calendar_example_01.c41
1 files changed, 41 insertions, 0 deletions
diff --git a/libraries/elementary/src/examples/calendar_example_01.c b/libraries/elementary/src/examples/calendar_example_01.c
new file mode 100644
index 0000000..f00cfc4
--- /dev/null
+++ b/libraries/elementary/src/examples/calendar_example_01.c
@@ -0,0 +1,41 @@
1/**
2 * Simple Elementary's <b>calendar widget</b> example, illustrating its
3 * creation.
4 *
5 * See stdout/stderr for output. Compile with:
6 *
7 * @verbatim
8 * gcc -o calendar_example_01 calendar_example_01.c -g `pkg-config --cflags --libs elementary`
9 * @endverbatim
10 */
11
12#include <Elementary.h>
13
14EAPI_MAIN int
15elm_main(int argc, char **argv)
16{
17 Evas_Object *win, *bg, *cal;
18
19 win = elm_win_add(NULL, "calendar", ELM_WIN_BASIC);
20 elm_win_title_set(win, "Calendar Creation Example");
21 elm_win_autodel_set(win, EINA_TRUE);
22 elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);
23
24 bg = elm_bg_add(win);
25 elm_win_resize_object_add(win, bg);
26 evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
27 evas_object_show(bg);
28
29 cal = elm_calendar_add(win);
30 elm_win_resize_object_add(win, cal);
31 evas_object_size_hint_weight_set(cal, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
32 evas_object_show(cal);
33
34 evas_object_show(win);
35
36 elm_run();
37 elm_shutdown();
38
39 return 0;
40}
41ELM_MAIN()