summaryrefslogtreecommitdiff
path: root/legacy/edje/doc
diff options
context:
space:
mode:
authorDavide Andreoli <dave@gurumeditation.it>2010-10-14 09:21:12 +0000
committerDavide Andreoli <dave@gurumeditation.it>2010-10-14 09:21:12 +0000
commit740e1626a2e56625b08a2d11f7bc8792279de18b (patch)
treeb6a637cb8ab98a8019187a4a2c5e415f604baf0f /legacy/edje/doc
parent958b6c7569ec0ecabd7804e3f7b4ea2e29a8dbe2 (diff)
The daily edje example: EXTERNAL elm Panes.
SVN revision: 53391
Diffstat (limited to 'legacy/edje/doc')
-rw-r--r--legacy/edje/doc/edje.dox.in3
-rw-r--r--legacy/edje/doc/examples/external_elm_panes.edc140
2 files changed, 143 insertions, 0 deletions
diff --git a/legacy/edje/doc/edje.dox.in b/legacy/edje/doc/edje.dox.in
index b172c1d30e..dd6c665ce4 100644
--- a/legacy/edje/doc/edje.dox.in
+++ b/legacy/edje/doc/edje.dox.in
@@ -487,6 +487,9 @@ This example create some elementary buttons and do some actions on user click.
487@example external_elm_check.edc 487@example external_elm_check.edc
488This example show EXTERNAL checkbox in action. 488This example show EXTERNAL checkbox in action.
489 489
490@example external_elm_panes.edc
491This example show EXTERNAL elementary panes in action.
492
490@example external_emotion_elm.edc 493@example external_emotion_elm.edc
491Super-concise video player example using Edje/Emotion/Elementary. 494Super-concise video player example using Edje/Emotion/Elementary.
492 495
diff --git a/legacy/edje/doc/examples/external_elm_panes.edc b/legacy/edje/doc/examples/external_elm_panes.edc
new file mode 100644
index 0000000000..8833668f7c
--- /dev/null
+++ b/legacy/edje/doc/examples/external_elm_panes.edc
@@ -0,0 +1,140 @@
1collections {
2 /* tell edje that we are going to use elementary external parts */
3 externals {
4 external: "elm";
5 }
6
7 /* those groups are the buttons used as content for the panes */
8 group { name: "button1";
9 parts {
10 part { name: "btn";
11 type: EXTERNAL;
12 source: "elm/button";
13 description { state: "default" 0.0;
14 params.string: "label" "Left";
15 }
16 }
17 }
18 }
19 group { name: "button2";
20 parts {
21 part { name: "btn";
22 type: EXTERNAL;
23 source: "elm/button";
24 description { state: "default" 0.0;
25 params.string: "label" "Top";
26 }
27 }
28 }
29 }
30 group { name: "button3";
31 parts {
32 part { name: "btn";
33 type: EXTERNAL;
34 source: "elm/button";
35 description { state: "default" 0.0;
36 params.string: "label" "Right";
37 }
38 }
39 }
40 }
41
42 /* this is the vertical panes */
43 group { name: "panes2";
44 parts {
45 part { name: "panes";
46 type: EXTERNAL;
47 source: "elm/panes";
48 description { state: "default" 0.0;
49 params {
50 bool: "horizontal" 1;
51 string: "content left" "button2";
52 string: "content right" "button3";
53 }
54 }
55 }
56 }
57 }
58
59 group { name: "main";
60 /* set a min window size */
61 min: 300 400;
62
63 parts {
64 part { name: "bg";
65 type: RECT;
66 description { state: "default" 0.0;
67 color: 255 255 255 255;
68 }
69 }
70
71 part { name: "title";
72 type: TEXT;
73 effect: SOFT_SHADOW;
74 description { state: "default" 0.0;
75 color: 255 255 255 255;
76 color3: 70 70 70 70;
77 text {
78 text: "Elementary Panes";
79 font: "Sans";
80 size: 16;
81 align: 0.5 0.0;
82 }
83 }
84 }
85
86 /* first panes (horiz) */
87 part { name: "panes1";
88 type: EXTERNAL;
89 source: "elm/panes";
90 description { state: "default" 0.0;
91 rel1.offset: 0 35;
92 rel2.offset: 0 -45;
93 params {
94 string: "content left" "button1";
95 string: "content right" "panes2";
96 }
97 }
98 description { state: "swapped" 0.0;
99 inherit: "default" 0.0;
100 params {
101 string: "content left" "panes2";
102 string: "content right" "button1";
103 }
104 }
105 }
106
107 /* button used to swap the content of the panes1 */
108 part { name: "swap_button";
109 type: EXTERNAL;
110 source: "elm/button";
111 description { state: "default" 0.0;
112 rel1 {
113 relative: 0.0 1.0;
114 offset: 0 -40;
115 }
116 params {
117 string: "label" "Swap & back";
118 }
119 }
120 }
121 }
122
123 programs {
124 /* when button is pressed set the 'swapped' state */
125 program { name: "swap";
126 signal: "clicked";
127 source: "swap_button";
128 action: STATE_SET "swapped" 0.0;
129 target: "panes1";
130 after: "go_back";
131 }
132 /* after 1 second return to the 'default' state */
133 program { name: "go_back";
134 in: 1.0 0.0;
135 action: STATE_SET "default" 0.0;
136 target: "panes1";
137 }
138 }
139 }
140}