summaryrefslogtreecommitdiff
path: root/legacy/edje/doc/examples/external_elm_anchorblock.edc
blob: 33f99daa433022912ecdc0298a63dc0a6c5e2211 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160

#define LOREM "Vestibulum nunc mi, adipiscing dapibus turpis. Integer ornare \
vestibulum. Quisque libero augue, non tristique tortor. Praesent urna augue, \
blandit id sodales vel, varius at purus. Ut congue mollis elit, quis vehicula \
enim ornare vitae. Suspendisse non faucibus massa. Nunc facilisis sapien ut \
erat laoreet vitae pharetra purus commodo. Donec in ipsum justo, sit amet \
lacinia massa. Pellentesque sed dolor lectus. Integer nec nisi ut massa \
vestibulum vulputate mollis ut lacus. Morbi lobortis dictum lacus nec \
faucibus. <item relsize=16x16 vsize=full href=emoticon/angry></item> \
<item relsize=16x16 vsize=full href=emoticon/evil></item> \
<item relsize=16x16 vsize=full href=emoticon/google-smile></item> \
<item relsize=16x16 vsize=full href=emoticon/omg></item><br><br> \
Phasellus ultricies nisl sit amet ligula tristique in adipiscing neque \
vulputate. Maecenas est ante, porttitor eget commodo non, blandit et erat. \
Duis adipiscing, tortor quis gravida vulputate, magna lorem mollis tortor, \
elementum ullamcorper dui mi ut metus. Nunc dictum nisi sed arcu mattis \
pellentesque. Aliquam erat volutpat. Nullam faucibus suscipit dui a \
condimentum. Fusce a diam tortor. Curabitur egestas gravida magna, eget \
lacinia magna fringilla in. Donec eget tincidunt ipsum. Suspendisse velit \
massa, sollicitudin in laoreet a, posuere malesuada enim. \
Duis a nulla purus.<br><br> \
Aenean nec sodales lacus. Sed ipsum felis, blandit sed aliquet ac, viverra \
vitae odio. Proin nisi nisi, commodo at cursus ut, auctor at elit. Sed tempor \
placerat orci eget venenatis. Duis ut dolor nibh, non luctus tellus. Duis \
placerat aliquet sem, et dignissim tellus rutrum at. Etiam sapien lacus, \
auctor quis interdum vel, pellentesque sit amet arcu. Proin accumsan, mauris \
non dapibus fermentum, nisl leo cursus nisi, eget auctor lacus ante a nisl. \
Suspendisse ullamcorper suscipit mi, et blandit augue aliquet non. Aenean \
vulputate ullamcorper ante, ut tincidunt orci sagittis nec. In hendrerit nunc \
eget sapien eleifend luctus. Pellentesque vulputate diam ac arcu suscipit nec \
vestibulum dolor blandit. Sed et massa vel ante tempor fermentum nec ac arcu. \
Duis turpis odio, vehicula sit amet pellentesque non, facilisis quis ligula. \
Sed ante nisl, cursus in pulvinar in, interdum vitae diam. Cras condimentum \
diam ac purus tempor suscipit eget sed metus. Nam erat nunc, eleifend vitae \
vehicula vitae, venenatis faucibus est. Nam auctor mauris metus. Nam eget \
vehicula nunc. Nulla ut nisi id sapien rhoncus vestibulum."

collections {
   group { name: "main";
      /* set a min window size */
      min: 300 400;

      /* tell edje that we are going to use elementary external parts */
      externals {
         external: "elm";
      }

      parts {
         part { name: "bg";
            type: RECT;
            description { state: "default" 0.0;
               color: 255 255 255 255;
            }
         }

         part { name: "title";
            type: TEXT;
            effect: SOFT_SHADOW;
            description { state: "default" 0.0;
               color: 255 255 255 255;
               color3: 70 70 70 70;
               text {
                  text: "Elementary Anchorblock";
                  font: "Sans";
                  size: 16;
                  align: 0.5 0.0;
               }
            }
         }

         /* EXTERNAL elementary anchorblock */
         part { name: "anchorblock";
            type: EXTERNAL;
            source: "elm/anchorblock";
            description { state: "default" 0.0;
               color: 200 200 0 200;
               rel1.offset: 5 35;
               rel2.offset: -6 -45;
               align: 0.0 0.0;
               map {
                  on: 1;
                  perspective_on: 1;
                  smooth: 1;
               }
               params.string: "text" LOREM;
            }
            description { state: "anim" 0.0;
               inherit: "default" 0.0;
               map.rotation.z: 100;
            }
            description { state: "anim" 0.1;
               inherit: "default" 0.0;
               map.rotation.y: 180;
            }
            description { state: "anim" 0.2;
               inherit: "default" 0.0;
               map.rotation.x: 150;
            }
            description { state: "anim" 0.3;
               inherit: "default" 0.0;
               map.rotation.z: 100;
               map.rotation.y: 100;
            }
         }
   
         /* EXTERNAL elementary button to trigger the animation */
         part { name: "button";
            type: EXTERNAL;
            source: "elm/button";
            description { state: "default" 0;
               rel1 {
                  relative: 0.0 1.0;
                  offset: 5 -40;
               }
               rel2 {
                  offset: -6 -2;
               }
               params {
                  string: "label" "Animate";
               }
            }
         }
      }

      programs {
         /* button clicked, start the animation cycle */
         program { name: "button_click";
            signal: "clicked";
            source: "button";
            action: STATE_SET "anim" 0.0;
            transition: LINEAR 1.0;
            target: "anchorblock";
            after: "anim2";
         }
         program { name: "anim2";
            action: STATE_SET "anim" 0.1;
            transition: LINEAR 1.0;
            target: "anchorblock";
            after: "anim3";
         }
         program { name: "anim3";
            action: STATE_SET "anim" 0.2;
            transition: LINEAR 1.0;
            target: "anchorblock";
            after: "anim4";
         }
         program { name: "anim4";
            action: STATE_SET "anim" 0.3;
            transition: LINEAR 1.0;
            target: "anchorblock";
            after: "anim5";
         }
         program { name: "anim5";
            action: STATE_SET "default" 0.0;
            transition: LINEAR 1.0;
            target: "anchorblock";
         }
      }
   }
}