85ba4ae4bb84671f07a2f81ba8b2c4a16ebffafb
[apps/core/preloaded/calendar.git] / data / edc / layout / inc.main.week.edc
1 /*
2   *
3   *  Copyright 2012  Samsung Electronics Co., Ltd
4   *
5   *  Licensed under the Flora License, Version 1.0 (the "License");
6   *  you may not use this file except in compliance with the License.
7   *  You may obtain a copy of the License at
8   *
9   *       http://floralicense.org/license/
10   *
11   *  Unless required by applicable law or agreed to in writing, software
12   *  distributed under the License is distributed on an "AS IS" BASIS,
13   *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   *  See the License for the specific language governing permissions and
15   *  limitations under the License.
16   */
17
18 /*
19
20         There are 9 configurations for each part definition.
21
22         That is, if you search for a part, 9 results will come up.
23
24         The order of the definitions are as follows:
25
26                 WDB
27                 WDB_S
28                 WDB_S           (Public)
29                 LS_WDB_S
30                 LS_WDB_S        (Public)
31                 WDB_S_S
32                 WDB_S_S         (Public)
33                 LS_WDB_S_S
34                 LS_WDB_S_S      (Public)
35
36         "LS_" denotes landscape
37
38 */
39
40 // 462 x 580
41 // day block in week view
42 #define WEEK_DAY_X_LEFT_COORD_RATIO(_pos) (_pos % 2 / 2)
43 #define WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) (_pos % 2 / 2 + 1 / 2)
44
45 #define LS_WEEK_DAY_X_LEFT_COORD_RATIO(_pos) (_pos % 3 / 3)
46 #define LS_WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) (_pos % 3 / 3 + 1 / 3)
47
48 #define WEEK_DAY_WDB_Y_TOP_COORD_RATIO(_pos) (_pos / 2 / 4 - _pos % 2 / 2 / 4)
49 #define WEEK_DAY_WDB_Y_BOTTOM_COORD_RATIO(_pos) (_pos / 2 / 4 - _pos % 2 / 2 / 4 + 1 / 4)
50
51
52 #define WEEK_DAY_WDB_Y_EXPAND_DOWN_BOTTOM_COORD_RATIO(_pos) (_pos / 2 / 4 - _pos % 2 / 2 / 4 + 1 / 4 + 1 / 4)
53 #define WEEK_DAY_WDB_Y_EXPAND_UP_TOP_COORD_RATIO(_pos) (_pos / 2 / 4 - _pos % 2 / 2 / 4 - 1 / 4)
54
55 #define WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos) (_pos / 2 / 3 - _pos % 2 / 2 / 3)
56 #define WEEK_DAY_WDB_S_Y_BOTTOM_COORD_RATIO(_pos) (_pos / 2 / 3 - _pos % 2 / 2 / 3 + 1 / 3)
57
58 #define LS_WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos) (_pos / 3 / 2 - _pos % 3 / 3 / 2)
59 #define LS_WEEK_DAY_WDB_S_Y_BOTTOM_COORD_RATIO(_pos) (_pos / 3 / 2 - _pos % 3 / 3 / 2 + 1 / 2)
60
61 #define WEEK_DAY_WDB_S_Y_EXPAND_DOWN_BOTTOM_COORD_RATIO(_pos) (_pos / 2 / 3 - _pos % 2 / 2 / 3 + 1 / 3 + 1 / 3)
62 #define WEEK_DAY_WDB_S_Y_EXPAND_UP_TOP_COORD_RATIO(_pos) (_pos / 2 / 3 - _pos % 2 / 2 / 3 - 1 / 3)
63
64 #define LS_WEEK_DAY_WDB_S_Y_EXPAND_DOWN_BOTTOM_COORD_RATIO(_pos) (_pos / 3 / 2 - _pos % 3 / 3 / 2 + 1 / 2 + 1 / 2)
65 #define LS_WEEK_DAY_WDB_S_Y_EXPAND_UP_TOP_COORD_RATIO(_pos) (_pos / 3 / 2 - _pos % 3 / 3 / 2 - 1 / 2)
66
67 #define WEEK_DAY_WDB_S_S_Y_TOP_COORD_RATIO(_pos) (_pos*2 / 2 / 6 - 1/ 6)
68 #define WEEK_DAY_WDB_S_S_Y_BOTTOM_COORD_RATIO(_pos)     (_pos*2 / 2 / 6)
69 #define WEEK_DAY_WDB_S_S_Y_EXPAND_HIDE_UP_TOP_COORD_RATIO(_pos) (_pos*2 / 2 / 6 - 1/ 6 - 1 / 3)
70 #define WEEK_DAY_WDB_S_S_Y_EXPAND_UP_1_TOP_COORD_RATIO(_pos) (_pos*2 / 2 / 6 + 1 / 6)
71 #define WEEK_DAY_WDB_S_S_Y_EXPAND_UP_2_TOP_COORD_RATIO(_pos) (_pos*2 / 2 / 6 - 1/ 6 - 1 / 2)
72
73 #define LS_WEEK_DAY_WDB_S_S_Y_TOP_COORD_RATIO(_pos) (_pos / 4 - 3 /4)
74 #define LS_WEEK_DAY_WDB_S_S_Y_BOTTOM_COORD_RATIO(_pos)  (_pos / 4 - 1 / 2)
75 #define LS_WEEK_DAY_WDB_S_S_Y_EXPAND_HIDE_UP_TOP_COORD_RATIO(_pos)      (_pos /4 - 3 / 4 - 1 / 2)
76 #define LS_WEEK_DAY_WDB_S_S_Y_EXPAND_UP_1_TOP_COORD_RATIO(_pos) (_pos*2 / 2 / 6 + 1 / 6)
77 #define LS_WEEK_DAY_WDB_S_S_Y_EXPAND_UP_2_TOP_COORD_RATIO(_pos) (_pos*2 / 2 / 6 - 1/ 6 - 1 / 2)
78
79 #define WEEK_DAY_TITLE_HEIGHT 57
80 #define LS_WEEK_DAY_TITLE_HEIGHT 57
81
82 #define WEEK_ITEM_WIDTH 359
83 #define LS_WEEK_ITEM_WIDTH 359
84
85 #define WEEK_ITEM_HEIGHT 57
86 #define WEEK_ITEM_RIGHT_OFFSET 8
87 #define WEEK_ITEM_EXPAND_BUTTON_WIDTH 24
88 #define WEEK_ITEM_TITLE_DAY_HEIGHT 40
89 #define WEEK_ITEM_TITLE_DAY_WIDTH 45
90 #define WEEK_ITEM_TITLE_MORE_WIDTH 40
91
92 #define WEEK_ITEM_TITLE_WDAY_HEIGHT 28
93 #define WEEK_ITEM_TITLE_WDAY_OFFSET 6
94
95 #define LS_WEEK_ITEM_HEIGHT 57
96 #define LS_WEEK_ITEM_RIGHT_OFFSET 8
97 #define LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH 24
98 #define LS_WEEK_ITEM_TITLE_DAY_HEIGHT 40
99 #define LS_WEEK_ITEM_TITLE_DAY_WIDTH 45
100 #define LS_WEEK_ITEM_TITLE_MORE_WIDTH 40
101
102 #define LS_WEEK_ITEM_TITLE_WDAY_HEIGHT 28
103 #define LS_WEEK_ITEM_TITLE_WDAY_OFFSET 6
104
105 #define WDB(_pos) \
106         part { name, "wdb/"#_pos"/base"; \
107                 type, RECT; \
108                 description { \
109                         state, "default" 0.0; \
110                         rel1 { \
111                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
112                                         WEEK_DAY_WDB_Y_TOP_COORD_RATIO(_pos); \
113                                 to, "wdb/base"; \
114                         } \
115                         rel2 { \
116                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
117                                         WEEK_DAY_WDB_Y_BOTTOM_COORD_RATIO(_pos); \
118                                 to, "wdb/base"; \
119                         } \
120                         color, 0 0 0 0; \
121                 } \
122                 description { \
123                         state: "expand_hide_up" 0.0; \
124                         inherit: "default" 0.0; \
125                         rel1 { \
126                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
127                                         WEEK_DAY_WDB_Y_TOP_COORD_RATIO(_pos); \
128                                 to, "wdb/base"; \
129                         } \
130                         rel2 { \
131                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
132                                         WEEK_DAY_WDB_Y_TOP_COORD_RATIO(_pos); \
133                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
134                                 to, "wdb/base"; \
135                         } \
136                 } \
137                 description { \
138                         state: "expand_hide_down" 0.0; \
139                         inherit: "default" 0.0; \
140                         rel1 { \
141                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
142                                         WEEK_DAY_WDB_Y_BOTTOM_COORD_RATIO(_pos); \
143                                 offset, 0 -WEEK_DAY_TITLE_HEIGHT; \
144                                 to, "wdb/base"; \
145                         } \
146                         rel2 { \
147                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
148                                         WEEK_DAY_WDB_Y_BOTTOM_COORD_RATIO(_pos); \
149                                 to, "wdb/base"; \
150                         } \
151                 } \
152                 description { \
153                         state, "expand_down" 0.0; \
154                         rel1 { \
155                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
156                                         WEEK_DAY_WDB_Y_TOP_COORD_RATIO(_pos); \
157                                 to, "wdb/base"; \
158                         } \
159                         rel2 { \
160                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
161                                         WEEK_DAY_WDB_Y_EXPAND_DOWN_BOTTOM_COORD_RATIO(_pos); \
162                                 offset, 0 -WEEK_DAY_TITLE_HEIGHT; \
163                                 to, "wdb/base"; \
164                         } \
165                         color, 0 0 0 0; \
166                 } \
167                 description { \
168                         state, "expand_up" 0.0; \
169                         rel1 { \
170                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
171                                         WEEK_DAY_WDB_Y_EXPAND_UP_TOP_COORD_RATIO(_pos); \
172                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
173                                 to, "wdb/base"; \
174                         } \
175                         rel2 { \
176                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
177                                         WEEK_DAY_WDB_Y_BOTTOM_COORD_RATIO(_pos); \
178                                 to, "wdb/base"; \
179                         } \
180                         color, 0 0 0 0; \
181                 } \
182         } \
183         part { name, "wdb/"#_pos"/sel"; \
184                 mouse_events, 0; \
185                 description { \
186                         state, "default" 0.0; \
187                         rel1.to, "wdb/"#_pos"/base"; \
188                         rel2 { \
189                                 offset, 0 0; \
190                                 to, "wdb/"#_pos"/base"; \
191                         } \
192                         image { \
193                                 normal, CALENDAR_SELSECTED; \
194                                 border, 3 3 3 3; \
195                                 border_scale, 1; \
196                         } \
197                         visible, 0; \
198                 } \
199                 description { \
200                         state, "selected" 0.0; \
201                         inherit, "default" 0.0; \
202                         visible, 1; \
203                 } \
204         } \
205         part { name, "wdb/"#_pos"/bg"; \
206                 mouse_events, 0; \
207                 description { \
208                         state, "default" 0.0; \
209                         rel1.to, "wdb/"#_pos"/base"; \
210                         rel2.to, "wdb/"#_pos"/base"; \
211                         image.normal, CALENDAR_WEEK_VIEW_PRESS; \
212                         visible, 0; \
213                 } \
214                 description { \
215                         state, "down" 0.0; \
216                         inherit, "default" 0.0; \
217                         visible, 1; \
218                 } \
219         } \
220         part { name, "wdb/"#_pos"/title"; \
221                 type, RECT; \
222                 scale, 1; \
223                 mouse_events, 1; \
224                 description { \
225                         state, "default" 0.0; \
226                         rel1.to, "wdb/"#_pos"/base"; \
227                         rel2 { \
228                                 relative, 1.0 0.0; \
229                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
230                                 to, "wdb/"#_pos"/base"; \
231                         } \
232                         align, 0.5 0.0; \
233                         color, COLOR_OF_WEEK_ITEM_TITLE; \
234                 } \
235         } \
236         part { name, "wdb/"#_pos"/text"; \
237                 type, TEXT; \
238                 scale, 1; \
239                 mouse_events, 0; \
240                 description { \
241                         state, "default" 0.0; \
242                         rel1 { \
243                                 relative, (WEEK_ITEM_RIGHT_OFFSET/WEEK_ITEM_WIDTH) 0.0; \
244                                 to, "wdb/"#_pos"/title"; \
245                         } \
246                         rel2 { \
247                                 relative, ((WEEK_ITEM_RIGHT_OFFSET+WEEK_ITEM_TITLE_DAY_WIDTH)/WEEK_ITEM_WIDTH) 1.0; \
248                                 to, "wdb/"#_pos"/title"; \
249                         } \
250                         text { \
251                                 font, "SLP:style=Medium"; \
252                                 size, 40; \
253                                 align, 0.5 1.0; \
254                         } \
255                         color, 56 57 58 255; \
256                 } \
257                 description { \
258                         state, "sunday" 0.0; \
259                         inherit, "default" 0.0; \
260                         color, 200 0 0 255; \
261                 } \
262                 description { \
263                         state, "satday" 0.0; \
264                         inherit, "default" 0.0; \
265                         color, 0 0 200 255; \
266                 } \
267         } \
268         part { name, "wdb/"#_pos"/text_wday"; \
269                 type, TEXT; \
270                 scale, 1; \
271                 mouse_events, 0; \
272                 description { \
273                         state, "default" 0.0; \
274                         rel1 { \
275                                 relative, ((WEEK_ITEM_RIGHT_OFFSET+WEEK_ITEM_TITLE_DAY_WIDTH+WEEK_ITEM_TITLE_WDAY_OFFSET)/WEEK_ITEM_WIDTH) (((WEEK_ITEM_HEIGHT - WEEK_ITEM_TITLE_DAY_HEIGHT)/2+WEEK_ITEM_TITLE_DAY_HEIGHT-WEEK_ITEM_TITLE_WDAY_HEIGHT)/WEEK_ITEM_HEIGHT); \
276                                 to, "wdb/"#_pos"/title"; \
277                         } \
278                         rel2 { \
279                                 relative, 0.5 ((WEEK_ITEM_HEIGHT-(WEEK_ITEM_HEIGHT - WEEK_ITEM_TITLE_DAY_HEIGHT)/2)/WEEK_ITEM_HEIGHT); \
280                                 to, "wdb/"#_pos"/title"; \
281                         } \
282                         text { \
283                                 font, "SLP:style=Medium"; \
284                                 size, 19; \
285                                 align, 0.5 1.0; \
286                         } \
287                         color, 56 57 58 255; \
288                 } \
289                 description { \
290                         state, "sunday" 0.0; \
291                         inherit, "default" 0.0; \
292                         color, 200 0 0 255; \
293                 } \
294                 description { \
295                         state, "satday" 0.0; \
296                         inherit, "default" 0.0; \
297                         color, 0 0 200 255; \
298                 } \
299         } \
300         part { name, "wdb/"#_pos"/more"; \
301                 type, TEXT; \
302                 scale, 1; \
303                 mouse_events, 1; \
304                 description { \
305                         state, "default" 0.0; \
306                         rel1 { \
307                                 relative, (WEEK_ITEM_WIDTH-WEEK_ITEM_EXPAND_BUTTON_WIDTH-WEEK_ITEM_RIGHT_OFFSET-WEEK_ITEM_RIGHT_OFFSET-WEEK_ITEM_TITLE_MORE_WIDTH)/WEEK_ITEM_WIDTH 0.0; \
308                                 to, "wdb/"#_pos"/title"; \
309                         } \
310                         rel2 { \
311                                 relative, 0.0 1.0; \
312                                 to_x, "wdb/"#_pos"/expand_button"; \
313                                 to_y, "wdb/"#_pos"/title"; \
314                         } \
315                         text { \
316                                 font, "SLP:style=Medium"; \
317                                 size, 26; \
318                                 align, 0.0 0.5; \
319                                 text, "..."; \
320                         } \
321                         color, 7 180 211 255; \
322                 } \
323         } \
324         part { name, "wdb/"#_pos"/expand_button"; \
325                 mouse_events, 0; \
326                 description { \
327                         state, "default" 0.0; \
328                         rel1 { \
329                                 relative, ((WEEK_ITEM_WIDTH - WEEK_ITEM_RIGHT_OFFSET - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/WEEK_ITEM_WIDTH) ((WEEK_ITEM_HEIGHT - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2/WEEK_ITEM_HEIGHT); \
330                                 to, "wdb/"#_pos"/title"; \
331                         } \
332                         rel2 { \
333                                 relative,  ((WEEK_ITEM_WIDTH - WEEK_ITEM_RIGHT_OFFSET)/WEEK_ITEM_WIDTH) ((WEEK_ITEM_HEIGHT-((WEEK_ITEM_HEIGHT - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2))/WEEK_ITEM_HEIGHT); \
334                                 to, "wdb/"#_pos"/title"; \
335                         } \
336                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
337                         visible, 1; \
338                 } \
339                 description { \
340                         state, "expand_up" 0.0; \
341                         inherit, "default" 0.0; \
342                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
343                 } \
344                 description { \
345                         state, "expand_down" 0.0; \
346                         inherit, "default" 0.0; \
347                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
348                 } \
349                 description { \
350                         state, "expand_hide_up" 0.0; \
351                         inherit, "default" 0.0; \
352                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
353                 } \
354                 description { \
355                         state, "expand_hide_down" 0.0; \
356                         inherit, "default" 0.0; \
357                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
358                 } \
359         } \
360         part { name, "wdb/"#_pos"/check"; \
361                 mouse_events, 0; \
362                 scale, 1; \
363                 description { \
364                         state, "default" 0.0; \
365                         rel1 { \
366                                 relative, 0.1 0.5; \
367                                 to, "wdb/"#_pos"/text"; \
368                         } \
369                         rel2 { \
370                                 relative, 0.1 0.5; \
371                                 to, "wdb/"#_pos"/text"; \
372                         } \
373                         min, 44 44; \
374                         fixed, 1 1; \
375                         align, 0.5 0.5; \
376                         visible, 0; \
377                 } \
378                 description { \
379                         state, "checked" 0.0; \
380                         inherit, "default" 0.0; \
381                         visible, 1; \
382                 } \
383         } \
384         part { name, "wdb/"#_pos"/disable"; \
385                 type, SWALLOW; \
386                 description { \
387                         state, "default" 0.0; \
388                         rel1.to, "wdb/"#_pos"/base"; \
389                         rel2.to, "wdb/"#_pos"/base"; \
390                 } \
391         } \
392         part { name, "wdb/"#_pos"/sw"; \
393                 type, SWALLOW; \
394                 mouse_events, 1; \
395                 description { \
396                         state, "default" 0.0; \
397                         rel1 { \
398                                 relative, 0.0 1.0; \
399                                 to_x, "wdb/"#_pos"/base"; \
400                                 to_y, "wdb/"#_pos"/title"; \
401                         } \
402                         rel2.to, "wdb/"#_pos"/base"; \
403                         fixed, 1 1; \
404                 } \
405         } \
406         programs { \
407                 program { name, "wdb/"#_pos"/down"; \
408                         signal, "mouse,down,1"; \
409                         source, "wdb/"#_pos"/base"; \
410                         action, STATE_SET "down" 0.0; \
411                         target, "wdb/"#_pos"/bg"; \
412                 } \
413                 program { name, "wdb/"#_pos"/mouse_down"; \
414                         signal, "mouse,down,1"; \
415                         source, "wdb/"#_pos"/base"; \
416                         action, SIGNAL_EMIT #_pos "down"; \
417                 } \
418                 program { name, "wdb/"#_pos"/up"; \
419                         signal, "mouse,up,1"; \
420                         source, "wdb/"#_pos"/base"; \
421                         action, STATE_SET "default" 0.0; \
422                         target, "wdb/"#_pos"/bg"; \
423                 } \
424                 program { name, "wdb/"#_pos"/click"; \
425                         signal, "mouse,clicked,1"; \
426                         source, "wdb/"#_pos"/base"; \
427                         action, SIGNAL_EMIT #_pos "cal"; \
428                 } \
429                 program { name, "wdb/"#_pos"/weekday"; \
430                         signal, "weekday,"#_pos; \
431                         source, "prog"; \
432                         action, STATE_SET "default" 0.0; \
433                         target, "wdb/"#_pos"/text"; \
434                         target, "wdb/"#_pos"/text_wday"; \
435                 } \
436                 program { name, "wdb/"#_pos"/sunday"; \
437                         signal, "sunday,"#_pos; \
438                         source, "prog"; \
439                         action, STATE_SET "sunday" 0.0; \
440                         target, "wdb/"#_pos"/text"; \
441                         target, "wdb/"#_pos"/text_wday"; \
442                 } \
443                 program { name, "wdb/"#_pos"/satday"; \
444                         signal, "satday,"#_pos; \
445                         source, "prog"; \
446                         action, STATE_SET "satday" 0.0; \
447                         target, "wdb/"#_pos"/text"; \
448                         target, "wdb/"#_pos"/text_wday"; \
449                 } \
450                 program { name, "wdb/"#_pos"/select"; \
451                         signal, "select,"#_pos; \
452                         source, "prog"; \
453                         action, STATE_SET "selected" 0.0; \
454                         target, "wdb/"#_pos"/sel"; \
455                 } \
456                 program { name, "wdb/"#_pos"/unselect"; \
457                         signal, "unselect,"#_pos; \
458                         source, "prog"; \
459                         action, STATE_SET "default" 0.0; \
460                         target, "wdb/"#_pos"/sel"; \
461                 } \
462                 program { name, "wdb/"#_pos"/set_check"; \
463                         signal, "check,"#_pos; \
464                         source, "prog"; \
465                         action, STATE_SET "checked" 0.0; \
466                         target, "wdb/"#_pos"/check"; \
467                 } \
468                 program { name, "wdb/"#_pos"/unset_check"; \
469                         signal, "uncheck,"#_pos; \
470                         source, "prog"; \
471                         action, STATE_SET "default" 0.0; \
472                         target, "wdb/"#_pos"/check"; \
473                 } \
474                 program { name, "wdb/"#_pos"/expand_up"; \
475                         signal, "set_expand_up,"#_pos; \
476                         source, "prog"; \
477                         action, STATE_SET "expand_up" 0.0; \
478                         target, "wdb/"#_pos"/base"; \
479                         target,  "wdb/"#_pos"/expand_button"; \
480                 } \
481                 program { name, "wdb/"#_pos"/expand_down"; \
482                         signal, "set_expand_down,"#_pos; \
483                         source, "prog"; \
484                         action, STATE_SET "expand_down" 0.0; \
485                         target, "wdb/"#_pos"/base"; \
486                         target,  "wdb/"#_pos"/expand_button"; \
487                 } \
488                 program { name, "wdb/"#_pos"/expand_hide_up"; \
489                         signal, "set_expand_hide_up,"#_pos; \
490                         source, "prog"; \
491                         action, STATE_SET "expand_hide_up" 0.0; \
492                         target, "wdb/"#_pos"/base"; \
493                         target,  "wdb/"#_pos"/expand_button"; \
494                 } \
495                 program { name, "wdb/"#_pos"/expand_hide_down"; \
496                         signal, "set_expand_hide_down,"#_pos; \
497                         source, "prog"; \
498                         action, STATE_SET "expand_hide_down" 0.0; \
499                         target, "wdb/"#_pos"/base"; \
500                         target,  "wdb/"#_pos"/expand_button"; \
501                 } \
502                 program { name, "wdb/"#_pos"/expand_default"; \
503                         signal, "set_expand_default,"#_pos; \
504                         source, "prog"; \
505                         action, STATE_SET "default" 0.0; \
506                         target, "wdb/"#_pos"/base"; \
507                         target,  "wdb/"#_pos"/expand_button"; \
508                 } \
509                 program { name, "wdb/"#_pos"/more_clicked"; \
510                         signal, "mouse,clicked,1"; \
511                         source, "wdb/"#_pos"/title"; \
512                         action, SIGNAL_EMIT #_pos "more"; \
513                 } \
514         }
515
516 group { name, "main/week";
517
518         images {
519                 image, "57_calendar_week_view_press.png" COMP;
520                 image, "57_calendar_week_view_bg.png" COMP;
521                 image, "calendar_selected.png" COMP;
522                 image, "P01_week_view_icon_open.png" COMP;
523                 image, "P01_week_view_icon_close.png" COMP;
524         }
525
526         parts {
527                 part { name, "base";
528                         type, RECT;
529                         description {
530                                 state, "default" 0.0;
531                                 color, 248 246 239 255;
532                         }
533                 }
534
535                 part { name, "wdb/base";
536                         type, RECT;
537                         description {
538                                 state, "default" 0.0;
539                                 rel1 {
540                                         offset, 0 1;
541                                         to, "base";
542                                 }
543                                 rel2.to, "base";
544                                 color, 0 0 0 0;
545                         }
546                 }
547
548                 WDB( 0) WDB( 1)
549                 WDB( 2) WDB( 3)
550                 WDB( 4) WDB( 5)
551                 WDB( 6) WDB( 7)
552
553                 part { name, "wdb/line/top";
554                         type, RECT;
555                         description {
556                                 state, "default" 0.0;
557                                 rel1.to, "base";
558                                 rel2 {
559                                         relative, 1.0 0.0;
560                                         offset, -1 0;
561                                         to, "base";
562                                 }
563                                 color, 195 192 179 255;
564                         }
565                 }
566
567                 part { name, "wdb/line/vertical";
568                         type, RECT;
569                         description {
570                                 state, "default" 0.0;
571                                 rel1 {
572                                         relative, 0.5 0.0;
573                                         to, "base";
574                                 }
575                                 rel2 {
576                                         relative, 0.5 1.0;
577                                         offset, 0 -1;
578                                         to, "base";
579                                 }
580                                 color, 195 192 179 255;
581                         }
582                 }
583         }
584 }
585
586 #define LEFT_WDB_S_TITLE(_pos) \
587         part { name, "wdb/"#_pos"/top/line"; \
588                 type, RECT; \
589                 scale, 1; \
590                 mouse_events, 0; \
591                 description { \
592                         state, "default" 0.0; \
593                         min: 0 1; \
594                      fixed: 0 1; \
595                         rel1.to, "wdb/"#_pos"/base"; \
596                         rel2 { \
597                                 relative, 1.0 0.0; \
598                                 to, "wdb/"#_pos"/base"; \
599                         } \
600                         align, 0.0 0.0; \
601                         color, 143 143 143 255; \
602                 } \
603         } \
604         part { name, "wdb/"#_pos"/title"; \
605                 type, RECT; \
606                 scale, 1; \
607                 mouse_events, 1; \
608                 description { \
609                         state, "default" 0.0; \
610                          rel1 {\
611                            relative: 0.0 1.0;\
612                            to_x: "wdb/"#_pos"/base";\
613                            to_y: "wdb/"#_pos"/top/line";\
614                        } \
615                         rel2 { \
616                                 relative, 1.0 0.0; \
617                                 offset, -1 WEEK_DAY_TITLE_HEIGHT; \
618                                 to, "wdb/"#_pos"/base"; \
619                         } \
620                         align, 0.0 0.0; \
621                         color, COLOR_OF_WEEK_ITEM_TITLE; \
622                 } \
623                 description { \
624                         state, "default" 0.1; \
625                         inherit, "default" 0.0; \
626                         color, COLOR_OF_TODAY_FOR_WEEK_CAL; \
627                 } \
628         } \
629         part { name, "wdb/"#_pos"/title_bg"; \
630                 type, RECT; \
631                 scale, 1; \
632                 mouse_events, 0; \
633                 description { \
634                         state, "default" 0.0; \
635                          rel1 {\
636                            relative: 0.0 1.0;\
637                            offset, 1 0; \
638                            to_x: "wdb/"#_pos"/base";\
639                            to_y: "wdb/"#_pos"/top/line";\
640                        } \
641                         rel2 { \
642                                 relative, 1.0 0.0; \
643                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
644                                 to, "wdb/"#_pos"/base"; \
645                         } \
646                         align, 0.0 0.0; \
647                         color, COLOR_OF_WEEK_ITEM_TITLE; \
648                         visible, 0; \
649                 } \
650                 description { \
651                         state, "default" 0.1; \
652                         inherit, "default" 0.0; \
653                         color, 182 221 241 255; \
654                         visible, 1; \
655                 } \
656         }
657
658 #define RIGHT_WDB_S_TITLE(_pos) \
659         part { name, "wdb/"#_pos"/top/line"; \
660                 type, RECT; \
661                 scale, 1; \
662                 mouse_events, 0; \
663                 description { \
664                         state, "default" 0.0; \
665                         min: 0 1; \
666                      fixed: 0 1; \
667                         rel1.to, "wdb/"#_pos"/base"; \
668                         rel2 { \
669                                 relative, 1.0 0.0; \
670                                 to, "wdb/"#_pos"/base"; \
671                         } \
672                         align, 0.0 0.0; \
673                         color, 143 143 143 255; \
674                 } \
675         } \
676         part { name, "wdb/"#_pos"/title"; \
677                 type, RECT; \
678                 scale, 1; \
679                 mouse_events, 1; \
680                 description { \
681                         state, "default" 0.0; \
682                          rel1 {\
683                            relative: 0.0 1.0;\
684                            offset, 1 0; \
685                            to_x: "wdb/"#_pos"/base";\
686                            to_y: "wdb/"#_pos"/top/line";\
687                        } \
688                         rel2 { \
689                                 relative, 1.0 0.0; \
690                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
691                                 to, "wdb/"#_pos"/base"; \
692                         } \
693                         align, 0.0 0.0; \
694                         color, COLOR_OF_WEEK_ITEM_TITLE; \
695                 } \
696                 description { \
697                         state, "default" 0.1; \
698                         inherit, "default" 0.0; \
699                         color, COLOR_OF_TODAY_FOR_WEEK_CAL; \
700                 } \
701         } \
702         part { name, "wdb/"#_pos"/title_bg"; \
703                 type, RECT; \
704                 scale, 1; \
705                 mouse_events, 0; \
706                 description { \
707                         state, "default" 0.0; \
708                          rel1 {\
709                            relative: 0.0 1.0;\
710                            offset, 1 0; \
711                            to_x: "wdb/"#_pos"/base";\
712                            to_y: "wdb/"#_pos"/top/line";\
713                        } \
714                         rel2 { \
715                                 relative, 1.0 0.0; \
716                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
717                                 to, "wdb/"#_pos"/base"; \
718                         } \
719                         align, 0.0 0.0; \
720                         color, COLOR_OF_WEEK_ITEM_TITLE; \
721                         visible, 0; \
722                 } \
723                 description { \
724                         state, "default" 0.1; \
725                         inherit, "default" 0.0; \
726                         color, 182 221 241 255; \
727                         visible, 1; \
728                 } \
729         }
730
731 #define WDB_S(_pos) \
732         part { name, "wdb/"#_pos"/text"; \
733                 type, TEXT; \
734                 scale, 1; \
735                 mouse_events, 0; \
736                 description { \
737                         state, "default" 0.0; \
738                         rel1 { \
739                                 relative, (WEEK_ITEM_RIGHT_OFFSET/WEEK_ITEM_WIDTH) 0.0; \
740                                 to, "wdb/"#_pos"/title"; \
741                         } \
742                         rel2 { \
743                                 relative, ((WEEK_ITEM_RIGHT_OFFSET+WEEK_ITEM_TITLE_DAY_WIDTH)/WEEK_ITEM_WIDTH) 1.0; \
744                                 to, "wdb/"#_pos"/title"; \
745                         } \
746                         text { \
747                                 font, "SLP:style=Medium"; \
748                                 size, 40; \
749                                 align, 0.0 1.0; \
750                         } \
751                         color, 56 57 58 255; \
752                 } \
753                 description { \
754                         state, "sunday" 0.0; \
755                         inherit, "default" 0.0; \
756                         color, 200 0 0 255; \
757                 } \
758                 description { \
759                         state, "satday" 0.0; \
760                         inherit, "default" 0.0; \
761                         color, 0 0 200 255; \
762                 } \
763         } \
764         part { name, "wdb/"#_pos"/text_wday"; \
765                 type, TEXT; \
766                 scale, 1; \
767                 mouse_events, 0; \
768                 description { \
769                         state, "default" 0.0; \
770                         rel1 { \
771                                 relative, ((WEEK_ITEM_RIGHT_OFFSET+WEEK_ITEM_TITLE_DAY_WIDTH+WEEK_ITEM_TITLE_WDAY_OFFSET)/WEEK_ITEM_WIDTH) (((WEEK_ITEM_HEIGHT - WEEK_ITEM_TITLE_DAY_HEIGHT)/2+WEEK_ITEM_TITLE_DAY_HEIGHT-WEEK_ITEM_TITLE_WDAY_HEIGHT)/WEEK_ITEM_HEIGHT); \
772                                 to, "wdb/"#_pos"/title"; \
773                         } \
774                         rel2 { \
775                                 relative, 0.5 ((WEEK_ITEM_HEIGHT-(WEEK_ITEM_HEIGHT - WEEK_ITEM_TITLE_DAY_HEIGHT)/2)/WEEK_ITEM_HEIGHT); \
776                                 to, "wdb/"#_pos"/title"; \
777                         } \
778                         text { \
779                                 font, "SLP:style=Medium"; \
780                                 size, 19; \
781                                 align, 0.0 1.0; \
782                         } \
783                         color, 56 57 58 255; \
784                 } \
785                 description { \
786                         state, "sunday" 0.0; \
787                         inherit, "default" 0.0; \
788                         color, 200 0 0 255; \
789                 } \
790                 description { \
791                         state, "satday" 0.0; \
792                         inherit, "default" 0.0; \
793                         color, 0 0 200 255; \
794                 } \
795         } \
796         part { name, "wdb/"#_pos"/more"; \
797                 type, TEXT; \
798                 scale, 1; \
799                 mouse_events, 1; \
800                 description { \
801                         state, "default" 0.0; \
802                         rel1 { \
803                                 relative, (WEEK_ITEM_WIDTH-WEEK_ITEM_EXPAND_BUTTON_WIDTH-WEEK_ITEM_RIGHT_OFFSET-WEEK_ITEM_RIGHT_OFFSET-WEEK_ITEM_TITLE_MORE_WIDTH)/WEEK_ITEM_WIDTH 0.0; \
804                                 to, "wdb/"#_pos"/title"; \
805                         } \
806                         rel2 { \
807                                 relative, 0.0 1.0; \
808                                 to_x, "wdb/"#_pos"/expand_button"; \
809                                 to_y, "wdb/"#_pos"/title"; \
810                         } \
811                         text { \
812                                 font, "SLP:style=Medium"; \
813                                 size, 26; \
814                                 align, 0.0 0.5; \
815                                 text, "..."; \
816                         } \
817                         color, 7 180 211 255; \
818                 } \
819         } \
820         part { name, "wdb/"#_pos"/expand_button"; \
821                 mouse_events, 0; \
822                 description { \
823                         state, "default" 0.0; \
824                         rel1 { \
825                                 relative, ((WEEK_ITEM_WIDTH - WEEK_ITEM_RIGHT_OFFSET - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/WEEK_ITEM_WIDTH) ((WEEK_ITEM_HEIGHT - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2/WEEK_ITEM_HEIGHT); \
826                                 to, "wdb/"#_pos"/title"; \
827                         } \
828                         rel2 { \
829                                 relative,  ((WEEK_ITEM_WIDTH - WEEK_ITEM_RIGHT_OFFSET)/WEEK_ITEM_WIDTH) ((WEEK_ITEM_HEIGHT-((WEEK_ITEM_HEIGHT - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2))/WEEK_ITEM_HEIGHT); \
830                                 to, "wdb/"#_pos"/title"; \
831                         } \
832                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
833                         visible, 1; \
834                 } \
835                 description { \
836                         state, "expand_up" 0.0; \
837                         inherit, "default" 0.0; \
838                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
839                 } \
840                 description { \
841                         state, "expand_down" 0.0; \
842                         inherit, "default" 0.0; \
843                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
844                 } \
845                 description { \
846                         state, "expand_hide_up" 0.0; \
847                         inherit, "default" 0.0; \
848                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
849                 } \
850                 description { \
851                         state, "expand_hide_down" 0.0; \
852                         inherit, "default" 0.0; \
853                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
854                 } \
855         } \
856         part { name, "wdb/"#_pos"/check"; \
857                 mouse_events, 0; \
858                 scale, 1; \
859                 description { \
860                         state, "default" 0.0; \
861                         rel1 { \
862                                 relative, 0.1 0.5; \
863                                 to, "wdb/"#_pos"/text"; \
864                         } \
865                         rel2 { \
866                                 relative, 0.1 0.5; \
867                                 to, "wdb/"#_pos"/text"; \
868                         } \
869                         min, 44 44; \
870                         fixed, 1 1; \
871                         align, 0.5 0.5; \
872                         visible, 0; \
873                 } \
874                 description { \
875                         state, "checked" 0.0; \
876                         inherit, "default" 0.0; \
877                         visible, 1; \
878                 } \
879         } \
880         part { name, "wdb/"#_pos"/disable"; \
881                 type, SWALLOW; \
882                 description { \
883                         state, "default" 0.0; \
884                         rel1.to, "wdb/"#_pos"/base"; \
885                         rel2.to, "wdb/"#_pos"/base"; \
886                 } \
887         } \
888         part { name, "wdb/"#_pos"/sw"; \
889                 type, SWALLOW; \
890                 mouse_events, 1; \
891                 description { \
892                         state, "default" 0.0; \
893                         rel1 { \
894                                 relative, 0.0 1.0; \
895                                 to_x, "wdb/"#_pos"/base"; \
896                                 to_y, "wdb/"#_pos"/title"; \
897                         } \
898                         rel2.to, "wdb/"#_pos"/base"; \
899                         fixed, 1 1; \
900                 } \
901         } \
902
903 #define WBS_S_PROGRAMS(_pos) \
904                 program { name, "wdb/"#_pos"/mouse_down"; \
905                         signal, "mouse,down,1"; \
906                         source, "wdb/"#_pos"/base"; \
907                         action, SIGNAL_EMIT #_pos "down"; \
908                 } \
909                 program { name, "wdb/"#_pos"/click"; \
910                         signal, "mouse,clicked,1"; \
911                         source, "wdb/"#_pos"/base"; \
912                         action, SIGNAL_EMIT #_pos "cal"; \
913                 } \
914                 program { name, "wdb/"#_pos"/weekday"; \
915                         signal, "weekday,"#_pos; \
916                         source, "prog"; \
917                         action, STATE_SET "default" 0.0; \
918                         target, "wdb/"#_pos"/text"; \
919                         target, "wdb/"#_pos"/text_wday"; \
920                 } \
921                 program { name, "wdb/"#_pos"/sunday"; \
922                         signal, "sunday,"#_pos; \
923                         source, "prog"; \
924                         action, STATE_SET "sunday" 0.0; \
925                         target, "wdb/"#_pos"/text"; \
926                         target, "wdb/"#_pos"/text_wday"; \
927                 } \
928                 program { name, "wdb/"#_pos"/satday"; \
929                         signal, "satday,"#_pos; \
930                         source, "prog"; \
931                         action, STATE_SET "satday" 0.0; \
932                         target, "wdb/"#_pos"/text"; \
933                         target, "wdb/"#_pos"/text_wday"; \
934                 } \
935                 program { name, "wdb/"#_pos"/set_check"; \
936                         signal, "check,"#_pos; \
937                         source, "prog"; \
938                         action, STATE_SET "checked" 0.0; \
939                         target, "wdb/"#_pos"/check"; \
940                 } \
941                 program { name, "wdb/"#_pos"/unset_check"; \
942                         signal, "uncheck,"#_pos; \
943                         source, "prog"; \
944                         action, STATE_SET "default" 0.0; \
945                         target, "wdb/"#_pos"/check"; \
946                 } \
947                 program { name, "wdb/"#_pos"/expand_up"; \
948                         signal, "set_expand_up,"#_pos; \
949                         source, "prog"; \
950                         action, STATE_SET "expand_up" 0.0; \
951                         target, "wdb/"#_pos"/base"; \
952                         target, "wdb/"#_pos"/expand_button"; \
953                 } \
954                 program { name, "wdb/"#_pos"/expand_down"; \
955                         signal, "set_expand_down,"#_pos; \
956                         source, "prog"; \
957                         action, STATE_SET "expand_down" 0.0; \
958                         target, "wdb/"#_pos"/base"; \
959                         target, "wdb/"#_pos"/expand_button"; \
960                 } \
961                 program { name, "wdb/"#_pos"/expand_hide_down"; \
962                         signal, "set_expand_hide_down,"#_pos; \
963                         source, "prog"; \
964                         action, STATE_SET "expand_hide_down" 0.0; \
965                         target, "wdb/"#_pos"/base"; \
966                         target, "wdb/"#_pos"/expand_button"; \
967                 } \
968                 program { name, "wdb/"#_pos"/expand_hide_up"; \
969                         signal, "set_expand_hide_up,"#_pos; \
970                         source, "prog"; \
971                         action, STATE_SET "expand_hide_up" 0.0; \
972                         target, "wdb/"#_pos"/base"; \
973                         target, "wdb/"#_pos"/expand_button"; \
974                 } \
975                 program { name, "wdb/"#_pos"/expand_default"; \
976                         signal, "set_expand_default,"#_pos; \
977                         source, "prog"; \
978                         action, STATE_SET "default" 0.0; \
979                         target, "wdb/"#_pos"/base"; \
980                         target, "wdb/"#_pos"/expand_button"; \
981                 } \
982                 program { name, "wdb/"#_pos"/more_clicked"; \
983                         signal, "mouse,clicked,1"; \
984                         source, "wdb/"#_pos"/title"; \
985                         action, SIGNAL_EMIT #_pos "more"; \
986                 } \
987                 program { name, "wdb/"#_pos"/today_focus"; \
988                         signal, "focus,"#_pos",today"; \
989                         source, "prog"; \
990                         action, STATE_SET "default" 0.1; \
991                         target, "wdb/"#_pos"/title"; \
992                 } \
993                 program { name, "wdb/"#_pos"/today_unfocus"; \
994                         signal, "unfocus,"#_pos",today"; \
995                         source, "prog"; \
996                         action, STATE_SET "default" 0.0; \
997                         target, "wdb/"#_pos"/title"; \
998                 } \
999                 program { name, "wdb/"#_pos"/focus"; \
1000                         signal, "focus,"#_pos",wday"; \
1001                         source, "prog"; \
1002                         action, STATE_SET "default" 0.1; \
1003                         target, "wdb/"#_pos"/title_bg"; \
1004                 } \
1005                 program { name, "wdb/"#_pos"/unfocus"; \
1006                         signal, "unfocus,"#_pos",wday"; \
1007                         source, "prog"; \
1008                         action, STATE_SET "default" 0.0; \
1009                         target, "wdb/"#_pos"/title_bg"; \
1010                 } \
1011                 program { name, "wdb/"#_pos"/show_more"; \
1012                         signal, "show,"#_pos",more"; \
1013                         source, "prog"; \
1014                         action, STATE_SET "default" 0.0; \
1015                         target, "wdb/"#_pos"/more"; \
1016                 } \
1017                 program { name, "wdb/"#_pos"/hide_more"; \
1018                         signal, "hide,"#_pos",more"; \
1019                         source, "prog"; \
1020                         action, STATE_SET "default" 0.1; \
1021                         target, "wdb/"#_pos"/more"; \
1022                 } \
1023
1024 #define LS_WDB_S(_pos) \
1025         part { name, "wdb/"#_pos"/base"; \
1026                 type, RECT; \
1027                 description { \
1028                         state, "default" 0.0; \
1029                         rel1 { \
1030                                 relative, LS_WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
1031                                         LS_WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos); \
1032                                 to, "wdb/base"; \
1033                         } \
1034                         rel2 { \
1035                                 relative, LS_WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
1036                                         LS_WEEK_DAY_WDB_S_Y_BOTTOM_COORD_RATIO(_pos); \
1037                                 to, "wdb/base"; \
1038                         } \
1039                         color, 246 246 246 255;\
1040                 } \
1041                 description { \
1042                         state: "expand_hide_up" 0.0; \
1043                         inherit: "default" 0.0; \
1044                         rel1 { \
1045                                 relative, LS_WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
1046                                         LS_WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos); \
1047                                 to, "wdb/base"; \
1048                         } \
1049                         rel2 { \
1050                                 relative, LS_WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
1051                                         LS_WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos); \
1052                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
1053                                 to, "wdb/base"; \
1054                         } \
1055                 } \
1056                 description { \
1057                         state: "expand_hide_down" 0.0; \
1058                         inherit: "default" 0.0; \
1059                         rel1 { \
1060                                 relative, LS_WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
1061                                         LS_WEEK_DAY_WDB_S_Y_BOTTOM_COORD_RATIO(_pos); \
1062                                 offset, 0 -WEEK_DAY_TITLE_HEIGHT; \
1063                                 to, "wdb/base"; \
1064                         } \
1065                         rel2 { \
1066                                 relative, LS_WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
1067                                         LS_WEEK_DAY_WDB_S_Y_BOTTOM_COORD_RATIO(_pos); \
1068                                 to, "wdb/base"; \
1069                         } \
1070                 } \
1071                 description { \
1072                         state: "expand_down" 0.0; \
1073                         inherit: "default" 0.0; \
1074                         rel1 { \
1075                                 relative, LS_WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
1076                                         LS_WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos); \
1077                                 to, "wdb/base"; \
1078                         } \
1079                         rel2 { \
1080                                 relative, LS_WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
1081                                         LS_WEEK_DAY_WDB_S_Y_EXPAND_DOWN_BOTTOM_COORD_RATIO(_pos); \
1082                                 offset, 0 -WEEK_DAY_TITLE_HEIGHT; \
1083                                 to, "wdb/base"; \
1084                         } \
1085                         color, 255 255 255 255;\
1086                 } \
1087                 description { \
1088                         state: "expand_up" 0.0; \
1089                         inherit: "default" 0.0; \
1090                         rel1 { \
1091                                 relative, LS_WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
1092                                         LS_WEEK_DAY_WDB_S_Y_EXPAND_UP_TOP_COORD_RATIO(_pos); \
1093                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
1094                                 to, "wdb/base"; \
1095                         } \
1096                         rel2 { \
1097                                 relative, LS_WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
1098                                         LS_WEEK_DAY_WDB_S_Y_BOTTOM_COORD_RATIO(_pos); \
1099                                 to, "wdb/base"; \
1100                         } \
1101                         color, 255 255 255 255;\
1102                 } \
1103         } \
1104         part { name, "wdb/"#_pos"/sel"; \
1105                 mouse_events, 0; \
1106                 description { \
1107                         state, "default" 0.0; \
1108                         rel1.to, "wdb/"#_pos"/base"; \
1109                         rel2 { \
1110                                 offset, 0 0; \
1111                                 to, "wdb/"#_pos"/base"; \
1112                         } \
1113                         visible, 0; \
1114                 } \
1115                 description { \
1116                         state, "selected" 0.0; \
1117                         inherit, "default" 0.0; \
1118                         visible, 1; \
1119                 } \
1120         } \
1121         part { name, "wdb/"#_pos"/bg"; \
1122                 mouse_events, 0; \
1123                 description { \
1124                         state, "default" 0.0; \
1125                         rel1.to, "wdb/"#_pos"/base"; \
1126                         rel2.to, "wdb/"#_pos"/base"; \
1127                         visible, 0; \
1128                 } \
1129                 description { \
1130                         state, "down" 0.0; \
1131                         inherit, "default" 0.0; \
1132                         visible, 1; \
1133                 } \
1134         } \
1135         part { name, "wdb/"#_pos"/title"; \
1136                 type, RECT; \
1137                 scale, 1; \
1138                 mouse_events, 1; \
1139                 description { \
1140                         state, "default" 0.0; \
1141                         rel1.to, "wdb/"#_pos"/base"; \
1142                         rel2 { \
1143                                 relative, 1.0 0.0; \
1144                                 offset, 0 LS_WEEK_DAY_TITLE_HEIGHT; \
1145                                 to, "wdb/"#_pos"/base"; \
1146                         } \
1147                         align, 0.5 0.0; \
1148                         color, COLOR_OF_WEEK_ITEM_TITLE; \
1149                 } \
1150                 description { \
1151                         state, "default" 0.1; \
1152                         inherit, "default" 0.0; \
1153                         color, COLOR_OF_TODAY_FOR_WEEK_CAL; \
1154                 } \
1155         } \
1156         part { name, "wdb/"#_pos"/title_bg"; \
1157                 type, RECT; \
1158                 scale, 1; \
1159                 mouse_events, 0; \
1160                 description { \
1161                         state, "default" 0.0; \
1162                         rel1.to, "wdb/"#_pos"/base"; \
1163                         rel2 { \
1164                                 relative, 1.0 0.0; \
1165                                 offset, 0 LS_WEEK_DAY_TITLE_HEIGHT; \
1166                                 to, "wdb/"#_pos"/base"; \
1167                         } \
1168                         align, 0.5 0.0; \
1169                         color, COLOR_OF_WEEK_ITEM_TITLE; \
1170                         visible, 0; \
1171                 } \
1172                 description { \
1173                         state, "default" 0.1; \
1174                         inherit, "default" 0.0; \
1175                         color, 182 221 241 255; \
1176                         visible, 1; \
1177                 } \
1178         } \
1179         part { name, "wdb/"#_pos"/text"; \
1180                 type, TEXT; \
1181                 scale, 1; \
1182                 mouse_events, 0; \
1183                 description { \
1184                         state, "default" 0.0; \
1185                         rel1 { \
1186                                 relative, (LS_WEEK_ITEM_RIGHT_OFFSET/LS_WEEK_ITEM_WIDTH) 0.0; \
1187                                 to, "wdb/"#_pos"/title"; \
1188                         } \
1189                         rel2 { \
1190                                 relative, ((LS_WEEK_ITEM_RIGHT_OFFSET+LS_WEEK_ITEM_TITLE_DAY_WIDTH)/LS_WEEK_ITEM_WIDTH) 1.0; \
1191                                 to, "wdb/"#_pos"/title"; \
1192                         } \
1193                         text { \
1194                                 font, "SLP:style=Medium"; \
1195                                 size, 40; \
1196                                 align, 0.0 1.0; \
1197                         } \
1198                         color, 56 57 58 255; \
1199                 } \
1200                 description { \
1201                         state, "sunday" 0.0; \
1202                         inherit, "default" 0.0; \
1203                         color, 200 0 0 255; \
1204                 } \
1205                 description { \
1206                         state, "satday" 0.0; \
1207                         inherit, "default" 0.0; \
1208                         color, 0 0 200 255; \
1209                 } \
1210         } \
1211         part { name, "wdb/"#_pos"/text_wday"; \
1212                 type, TEXT; \
1213                 scale, 1; \
1214                 mouse_events, 0; \
1215                 description { \
1216                         state, "default" 0.0; \
1217                         rel1 { \
1218                                 relative, ((LS_WEEK_ITEM_RIGHT_OFFSET+LS_WEEK_ITEM_TITLE_DAY_WIDTH+LS_WEEK_ITEM_TITLE_WDAY_OFFSET)/LS_WEEK_ITEM_WIDTH) (((LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_TITLE_DAY_HEIGHT)/2+LS_WEEK_ITEM_TITLE_DAY_HEIGHT-LS_WEEK_ITEM_TITLE_WDAY_HEIGHT)/LS_WEEK_ITEM_HEIGHT); \
1219                                 to, "wdb/"#_pos"/title"; \
1220                         } \
1221                         rel2 { \
1222                                 relative, 0.5 ((LS_WEEK_ITEM_HEIGHT-(LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_TITLE_DAY_HEIGHT)/2)/LS_WEEK_ITEM_HEIGHT); \
1223                                 to, "wdb/"#_pos"/title"; \
1224                         } \
1225                         text { \
1226                                 font, "SLP:style=Medium"; \
1227                                 size, 19; \
1228                                 align, 0.0 1.0; \
1229                         } \
1230                         color, 56 57 58 255; \
1231                 } \
1232                 description { \
1233                         state, "sunday" 0.0; \
1234                         inherit, "default" 0.0; \
1235                         color, 200 0 0 255; \
1236                 } \
1237                 description { \
1238                         state, "satday" 0.0; \
1239                         inherit, "default" 0.0; \
1240                         color, 0 0 200 255; \
1241                 } \
1242         } \
1243         part { name, "wdb/"#_pos"/more"; \
1244                 type, TEXT; \
1245                 scale, 1; \
1246                 mouse_events, 1; \
1247                 description { \
1248                         state, "default" 0.0; \
1249                         rel1 { \
1250                                 relative, (LS_WEEK_ITEM_WIDTH-LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH-LS_WEEK_ITEM_RIGHT_OFFSET-LS_WEEK_ITEM_RIGHT_OFFSET-LS_WEEK_ITEM_TITLE_MORE_WIDTH)/LS_WEEK_ITEM_WIDTH 0.0; \
1251                                 to, "wdb/"#_pos"/title"; \
1252                         } \
1253                         rel2 { \
1254                                 relative, 0.0 1.0; \
1255                                 to_x, "wdb/"#_pos"/expand_button"; \
1256                                 to_y, "wdb/"#_pos"/title"; \
1257                         } \
1258                         text { \
1259                                 font, "SLP:style=Medium"; \
1260                                 size, 26; \
1261                                 align, 0.0 0.5; \
1262                                 text, "..."; \
1263                         } \
1264                         color, 7 180 211 255; \
1265                 } \
1266         } \
1267         part { name, "wdb/"#_pos"/expand_button"; \
1268                 mouse_events, 0; \
1269                 description { \
1270                         state, "default" 0.0; \
1271                         rel1 { \
1272                                 relative, ((LS_WEEK_ITEM_WIDTH - LS_WEEK_ITEM_RIGHT_OFFSET - LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH)/LS_WEEK_ITEM_WIDTH) ((LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2/LS_WEEK_ITEM_HEIGHT); \
1273                                 to, "wdb/"#_pos"/title"; \
1274                         } \
1275                         rel2 { \
1276                                 relative,  ((LS_WEEK_ITEM_WIDTH - LS_WEEK_ITEM_RIGHT_OFFSET)/LS_WEEK_ITEM_WIDTH) ((LS_WEEK_ITEM_HEIGHT-((LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2))/LS_WEEK_ITEM_HEIGHT); \
1277                                 to, "wdb/"#_pos"/title"; \
1278                         } \
1279                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
1280                         visible, 1; \
1281                 } \
1282                 description { \
1283                         state, "expand_up" 0.0; \
1284                         inherit, "default" 0.0; \
1285                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
1286                 } \
1287                 description { \
1288                         state, "expand_down" 0.0; \
1289                         inherit, "default" 0.0; \
1290                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
1291                 } \
1292                 description { \
1293                         state, "expand_hide_up" 0.0; \
1294                         inherit, "default" 0.0; \
1295                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
1296                 } \
1297                 description { \
1298                         state, "expand_hide_down" 0.0; \
1299                         inherit, "default" 0.0; \
1300                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
1301                 } \
1302         } \
1303         part { name, "wdb/"#_pos"/check"; \
1304                 mouse_events, 0; \
1305                 scale, 1; \
1306                 description { \
1307                         state, "default" 0.0; \
1308                         rel1 { \
1309                                 relative, 0.1 0.5; \
1310                                 to, "wdb/"#_pos"/text"; \
1311                         } \
1312                         rel2 { \
1313                                 relative, 0.1 0.5; \
1314                                 to, "wdb/"#_pos"/text"; \
1315                         } \
1316                         min, 44 44; \
1317                         fixed, 1 1; \
1318                         align, 0.5 0.5; \
1319                         visible, 0; \
1320                 } \
1321                 description { \
1322                         state, "checked" 0.0; \
1323                         inherit, "default" 0.0; \
1324                         visible, 1; \
1325                 } \
1326         } \
1327         part { name, "wdb/"#_pos"/disable"; \
1328                 type, SWALLOW; \
1329                 description { \
1330                         state, "default" 0.0; \
1331                         rel1.to, "wdb/"#_pos"/base"; \
1332                         rel2.to, "wdb/"#_pos"/base"; \
1333                 } \
1334         } \
1335         part { name, "wdb/"#_pos"/sw"; \
1336                 type, SWALLOW; \
1337                 mouse_events, 1; \
1338                 description { \
1339                         state, "default" 0.0; \
1340                         rel1 { \
1341                                 relative, 0.0 1.0; \
1342                                 to_x, "wdb/"#_pos"/base"; \
1343                                 to_y, "wdb/"#_pos"/title"; \
1344                         } \
1345                         rel2.to, "wdb/"#_pos"/base"; \
1346                         fixed, 1 1; \
1347                 } \
1348         } \
1349         programs { \
1350                 program { name, "wdb/"#_pos"/down"; \
1351                         signal, "mouse,down,1"; \
1352                         source, "wdb/"#_pos"/base"; \
1353                         action, STATE_SET "down" 0.0; \
1354                         target, "wdb/"#_pos"/bg"; \
1355                 } \
1356                 program { name, "wdb/"#_pos"/mouse_down"; \
1357                         signal, "mouse,down,1"; \
1358                         source, "wdb/"#_pos"/base"; \
1359                         action, SIGNAL_EMIT #_pos "down"; \
1360                 } \
1361                 program { name, "wdb/"#_pos"/up"; \
1362                         signal, "mouse,up,1"; \
1363                         source, "wdb/"#_pos"/base"; \
1364                         action, STATE_SET "default" 0.0; \
1365                         target, "wdb/"#_pos"/bg"; \
1366                 } \
1367                 program { name, "wdb/"#_pos"/click"; \
1368                         signal, "mouse,clicked,1"; \
1369                         source, "wdb/"#_pos"/base"; \
1370                         action, SIGNAL_EMIT #_pos "cal"; \
1371                 } \
1372                 program { name, "wdb/"#_pos"/weekday"; \
1373                         signal, "weekday,"#_pos; \
1374                         source, "prog"; \
1375                         action, STATE_SET "default" 0.0; \
1376                         target, "wdb/"#_pos"/text"; \
1377                         target, "wdb/"#_pos"/text_wday"; \
1378                 } \
1379                 program { name, "wdb/"#_pos"/sunday"; \
1380                         signal, "sunday,"#_pos; \
1381                         source, "prog"; \
1382                         action, STATE_SET "sunday" 0.0; \
1383                         target, "wdb/"#_pos"/text"; \
1384                         target, "wdb/"#_pos"/text_wday"; \
1385                 } \
1386                 program { name, "wdb/"#_pos"/satday"; \
1387                         signal, "satday,"#_pos; \
1388                         source, "prog"; \
1389                         action, STATE_SET "satday" 0.0; \
1390                         target, "wdb/"#_pos"/text"; \
1391                         target, "wdb/"#_pos"/text_wday"; \
1392                 } \
1393                 program { name, "wdb/"#_pos"/select"; \
1394                         signal, "select,"#_pos; \
1395                         source, "prog"; \
1396                         action, STATE_SET "selected" 0.0; \
1397                         target, "wdb/"#_pos"/sel"; \
1398                 } \
1399                 program { name, "wdb/"#_pos"/unselect"; \
1400                         signal, "unselect,"#_pos; \
1401                         source, "prog"; \
1402                         action, STATE_SET "default" 0.0; \
1403                         target, "wdb/"#_pos"/sel"; \
1404                 } \
1405                 program { name, "wdb/"#_pos"/set_check"; \
1406                         signal, "check,"#_pos; \
1407                         source, "prog"; \
1408                         action, STATE_SET "checked" 0.0; \
1409                         target, "wdb/"#_pos"/check"; \
1410                 } \
1411                 program { name, "wdb/"#_pos"/unset_check"; \
1412                         signal, "uncheck,"#_pos; \
1413                         source, "prog"; \
1414                         action, STATE_SET "default" 0.0; \
1415                         target, "wdb/"#_pos"/check"; \
1416                 } \
1417                 program { name, "wdb/"#_pos"/expand_up"; \
1418                         signal, "set_expand_up,"#_pos; \
1419                         source, "prog"; \
1420                         action, STATE_SET "expand_up" 0.0; \
1421                         target, "wdb/"#_pos"/base"; \
1422                         target, "wdb/"#_pos"/expand_button"; \
1423                 } \
1424                 program { name, "wdb/"#_pos"/expand_down"; \
1425                         signal, "set_expand_down,"#_pos; \
1426                         source, "prog"; \
1427                         action, STATE_SET "expand_down" 0.0; \
1428                         target, "wdb/"#_pos"/base"; \
1429                         target, "wdb/"#_pos"/expand_button"; \
1430                 } \
1431                 program { name, "wdb/"#_pos"/expand_hide_down"; \
1432                         signal, "set_expand_hide_down,"#_pos; \
1433                         source, "prog"; \
1434                         action, STATE_SET "expand_hide_down" 0.0; \
1435                         target, "wdb/"#_pos"/base"; \
1436                         target, "wdb/"#_pos"/expand_button"; \
1437                 } \
1438                 program { name, "wdb/"#_pos"/expand_hide_up"; \
1439                         signal, "set_expand_hide_up,"#_pos; \
1440                         source, "prog"; \
1441                         action, STATE_SET "expand_hide_up" 0.0; \
1442                         target, "wdb/"#_pos"/base"; \
1443                         target, "wdb/"#_pos"/expand_button"; \
1444                 } \
1445                 program { name, "wdb/"#_pos"/expand_default"; \
1446                         signal, "set_expand_default,"#_pos; \
1447                         source, "prog"; \
1448                         action, STATE_SET "default" 0.0; \
1449                         target, "wdb/"#_pos"/base"; \
1450                         target, "wdb/"#_pos"/expand_button"; \
1451                 } \
1452                 program { name, "wdb/"#_pos"/more_clicked"; \
1453                         signal, "mouse,clicked,1"; \
1454                         source, "wdb/"#_pos"/title"; \
1455                         action, SIGNAL_EMIT #_pos "more"; \
1456                 } \
1457                 program { name, "wdb/"#_pos"/today_focus"; \
1458                         signal, "focus,"#_pos",today"; \
1459                         source, "prog"; \
1460                         action, STATE_SET "default" 0.1; \
1461                         target, "wdb/"#_pos"/title"; \
1462                 } \
1463                 program { name, "wdb/"#_pos"/today_unfocus"; \
1464                         signal, "unfocus,"#_pos",today"; \
1465                         source, "prog"; \
1466                         action, STATE_SET "default" 0.0; \
1467                         target, "wdb/"#_pos"/title"; \
1468                 } \
1469                 program { name, "wdb/"#_pos"/focus"; \
1470                         signal, "focus,"#_pos",wday"; \
1471                         source, "prog"; \
1472                         action, STATE_SET "default" 0.1; \
1473                         target, "wdb/"#_pos"/title_bg"; \
1474                 } \
1475                 program { name, "wdb/"#_pos"/unfocus"; \
1476                         signal, "unfocus,"#_pos",wday"; \
1477                         source, "prog"; \
1478                         action, STATE_SET "default" 0.0; \
1479                         target, "wdb/"#_pos"/title_bg"; \
1480                 } \
1481                 program { name, "wdb/"#_pos"/show_more"; \
1482                         signal, "show,"#_pos",more"; \
1483                         source, "prog"; \
1484                         action, STATE_SET "default" 0.0; \
1485                         target, "wdb/"#_pos"/more"; \
1486                 } \
1487                 program { name, "wdb/"#_pos"/hide_more"; \
1488                         signal, "hide,"#_pos",more"; \
1489                         source, "prog"; \
1490                         action, STATE_SET "default" 0.1; \
1491                         target, "wdb/"#_pos"/more"; \
1492                 } \
1493         }
1494
1495 #define RIGHT_WDB_S_S_TITLE(_pos) \
1496         part { name, "wdb/"#_pos"/top/line"; \
1497                 type, RECT; \
1498                 scale, 1; \
1499                 mouse_events, 0; \
1500                 description { \
1501                         state, "default" 0.0; \
1502                         min: 0 1; \
1503                      fixed: 0 1;\
1504                         rel1.to, "wdb/"#_pos"/base"; \
1505                         rel2 { \
1506                                 relative, 1.0 0.0; \
1507                                 to, "wdb/"#_pos"/base"; \
1508                         } \
1509                         align, 0.0 0.0; \
1510                         color, 143 143 143 255; \
1511                 } \
1512         } \
1513         part { name, "wdb/"#_pos"/title"; \
1514                 type, RECT; \
1515                 scale, 1; \
1516                 mouse_events, 1; \
1517                 description { \
1518                         state, "default" 0.0; \
1519                          rel1 {\
1520                           relative: 0.0 1.0;\
1521                           offset, 1 0; \
1522                           to_x: "wdb/"#_pos"/base";\
1523                           to_y: "wdb/"#_pos"/top/line";\
1524                        } \
1525                         rel2 { \
1526                                 relative, 1.0 0.0; \
1527                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
1528                                 to, "wdb/"#_pos"/base"; \
1529                         } \
1530                         align, 0.5 0.0; \
1531                         color, COLOR_OF_WEEK_ITEM_TITLE; \
1532                 } \
1533                 description { \
1534                         state, "default" 0.1; \
1535                         inherit, "default" 0.0; \
1536                         color, COLOR_OF_TODAY_FOR_WEEK_CAL; \
1537                 } \
1538         } \
1539         part { name, "wdb/"#_pos"/title_bg"; \
1540                 type, RECT; \
1541                 scale, 1; \
1542                 mouse_events, 0; \
1543                 description { \
1544                         state, "default" 0.0; \
1545                          rel1 {\
1546                            relative: 0.0 1.0;\
1547                            offset, 1 0; \
1548                            to_x: "wdb/"#_pos"/base";\
1549                            to_y: "wdb/"#_pos"/top/line";\
1550                        } \
1551                         rel2 { \
1552                                 relative, 1.0 0.0; \
1553                                 offset, 0 WEEK_DAY_TITLE_HEIGHT; \
1554                                 to, "wdb/"#_pos"/base"; \
1555                         } \
1556                         align, 0.0 0.0; \
1557                         color, COLOR_OF_WEEK_ITEM_TITLE; \
1558                         visible, 0; \
1559                 } \
1560                 description { \
1561                         state, "default" 0.1; \
1562                         inherit, "default" 0.0; \
1563                         color, 182 221 241 255; \
1564                         visible, 1; \
1565                 } \
1566         }
1567
1568 #define WDB_S_S(_pos) \
1569         part { name, "wdb/"#_pos"/text"; \
1570                 type, TEXT; \
1571                 scale, 1; \
1572                 mouse_events, 0; \
1573                 description { \
1574                         state, "default" 0.0; \
1575                         rel1 { \
1576                                 relative, (WEEK_ITEM_RIGHT_OFFSET/WEEK_ITEM_WIDTH) 0.0; \
1577                                 to, "wdb/"#_pos"/title"; \
1578                         } \
1579                         rel2 { \
1580                                 relative, ((WEEK_ITEM_RIGHT_OFFSET+WEEK_ITEM_TITLE_DAY_WIDTH)/WEEK_ITEM_WIDTH) 1.0; \
1581                                 to, "wdb/"#_pos"/title"; \
1582                         } \
1583                         text { \
1584                                 font, "SLP:style=Medium"; \
1585                                 size, 40; \
1586                                 align, 0.0 1.0; \
1587                         } \
1588                         color, 56 57 58 255; \
1589                 } \
1590                 description { \
1591                         state, "sunday" 0.0; \
1592                         inherit, "default" 0.0; \
1593                         color, 200 0 0 255; \
1594                 } \
1595                 description { \
1596                         state, "satday" 0.0; \
1597                         inherit, "default" 0.0; \
1598                         color, 0 0 200 255; \
1599                 } \
1600         } \
1601         part { name, "wdb/"#_pos"/text_wday"; \
1602                 type, TEXT; \
1603                 scale, 1; \
1604                 mouse_events, 0; \
1605                 description { \
1606                         state, "default" 0.0; \
1607                         rel1 { \
1608                                 relative, ((WEEK_ITEM_RIGHT_OFFSET+WEEK_ITEM_TITLE_DAY_WIDTH+WEEK_ITEM_TITLE_WDAY_OFFSET)/WEEK_ITEM_WIDTH) (((WEEK_ITEM_HEIGHT - WEEK_ITEM_TITLE_DAY_HEIGHT)/2+WEEK_ITEM_TITLE_DAY_HEIGHT-WEEK_ITEM_TITLE_WDAY_HEIGHT)/WEEK_ITEM_HEIGHT); \
1609                                 to, "wdb/"#_pos"/title"; \
1610                         } \
1611                         rel2 { \
1612                                 relative, 0.5 ((WEEK_ITEM_HEIGHT-(WEEK_ITEM_HEIGHT - WEEK_ITEM_TITLE_DAY_HEIGHT)/2)/WEEK_ITEM_HEIGHT); \
1613                                 to, "wdb/"#_pos"/title"; \
1614                         } \
1615                         text { \
1616                                 font, "SLP:style=Medium"; \
1617                                 size, 19; \
1618                                 align, 0.0 1.0; \
1619                         } \
1620                         color, 56 57 58 255; \
1621                 } \
1622                 description { \
1623                         state, "sunday" 0.0; \
1624                         inherit, "default" 0.0; \
1625                         color, 200 0 0 255; \
1626                 } \
1627                 description { \
1628                         state, "satday" 0.0; \
1629                         inherit, "default" 0.0; \
1630                         color, 0 0 200 255; \
1631                 } \
1632         } \
1633         part { name, "wdb/"#_pos"/more"; \
1634                 type, TEXT; \
1635                 scale, 1; \
1636                 mouse_events, 1; \
1637                 description { \
1638                         state, "default" 0.0; \
1639                         rel1 { \
1640                                 relative, (WEEK_ITEM_WIDTH-WEEK_ITEM_EXPAND_BUTTON_WIDTH-WEEK_ITEM_RIGHT_OFFSET-WEEK_ITEM_RIGHT_OFFSET-WEEK_ITEM_TITLE_MORE_WIDTH)/WEEK_ITEM_WIDTH 0.0; \
1641                                 to, "wdb/"#_pos"/title"; \
1642                         } \
1643                         rel2 { \
1644                                 relative, 0.0 1.0; \
1645                                 to_x, "wdb/"#_pos"/expand_button"; \
1646                                 to_y, "wdb/"#_pos"/title"; \
1647                         } \
1648                         text { \
1649                                 font, "SLP:style=Medium"; \
1650                                 size, 26; \
1651                                 align, 0.0 0.5; \
1652                                 text, "..."; \
1653                         } \
1654                         color, 7 180 211 255; \
1655                 } \
1656         } \
1657         part { name, "wdb/"#_pos"/expand_button"; \
1658                 mouse_events, 0; \
1659                 description { \
1660                         state, "default" 0.0; \
1661                         rel1 { \
1662                                 relative, ((WEEK_ITEM_WIDTH - WEEK_ITEM_RIGHT_OFFSET - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/WEEK_ITEM_WIDTH) ((WEEK_ITEM_HEIGHT - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2/WEEK_ITEM_HEIGHT); \
1663                                 to, "wdb/"#_pos"/title"; \
1664                         } \
1665                         rel2 { \
1666                                 relative,  ((WEEK_ITEM_WIDTH - WEEK_ITEM_RIGHT_OFFSET)/WEEK_ITEM_WIDTH) ((WEEK_ITEM_HEIGHT-((WEEK_ITEM_HEIGHT - WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2))/WEEK_ITEM_HEIGHT); \
1667                                 to, "wdb/"#_pos"/title"; \
1668                         } \
1669                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
1670                         visible, 1; \
1671                 } \
1672                 description { \
1673                         state, "expand_up_1" 0.0; \
1674                         inherit, "default" 0.0; \
1675                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
1676                 } \
1677                 description { \
1678                         state, "expand_up_2" 0.0; \
1679                         inherit, "default" 0.0; \
1680                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
1681                 } \
1682                 description { \
1683                         state, "expand_hide_up" 0.0; \
1684                         inherit, "default" 0.0; \
1685                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
1686                 } \
1687                 description { \
1688                         state, "expand_hide_down" 0.0; \
1689                         inherit, "default" 0.0; \
1690                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
1691                 } \
1692         } \
1693         part { name, "wdb/"#_pos"/check"; \
1694                 mouse_events, 0; \
1695                 scale, 1; \
1696                 description { \
1697                         state, "default" 0.0; \
1698                         rel1 { \
1699                                 relative, 0.1 0.5; \
1700                                 to, "wdb/"#_pos"/text"; \
1701                         } \
1702                         rel2 { \
1703                                 relative, 0.1 0.5; \
1704                                 to, "wdb/"#_pos"/text"; \
1705                         } \
1706                         min, 44 44; \
1707                         fixed, 1 1; \
1708                         align, 0.5 0.5; \
1709                         visible, 0; \
1710                 } \
1711                 description { \
1712                         state, "checked" 0.0; \
1713                         inherit, "default" 0.0; \
1714                         visible, 1; \
1715                 } \
1716         } \
1717         part { name, "wdb/"#_pos"/disable"; \
1718                 type, SWALLOW; \
1719                 description { \
1720                         state, "default" 0.0; \
1721                         rel1.to, "wdb/"#_pos"/base"; \
1722                         rel2.to, "wdb/"#_pos"/base"; \
1723                 } \
1724         } \
1725         part { name, "wdb/"#_pos"/sw"; \
1726                 type, SWALLOW; \
1727                 mouse_events, 1; \
1728                 description { \
1729                         state, "default" 0.0; \
1730                         rel1 { \
1731                                 relative, 0.0 1.0; \
1732                                 to_x, "wdb/"#_pos"/base"; \
1733                                 to_y, "wdb/"#_pos"/title"; \
1734                         } \
1735                         rel2.to, "wdb/"#_pos"/base"; \
1736                         fixed, 1 1; \
1737                 } \
1738         } \
1739
1740 #define WBS_S_S_PROGRAMS(_pos) \
1741                 program { name, "wdb/"#_pos"/mouse_down"; \
1742                         signal, "mouse,down,1"; \
1743                         source, "wdb/"#_pos"/base"; \
1744                         action, SIGNAL_EMIT #_pos "down"; \
1745                 } \
1746                 program { name, "wdb/"#_pos"/click"; \
1747                         signal, "mouse,clicked,1"; \
1748                         source, "wdb/"#_pos"/base"; \
1749                         action, SIGNAL_EMIT #_pos "cal"; \
1750                 } \
1751                 program { name, "wdb/"#_pos"/weekday"; \
1752                         signal, "weekday,"#_pos; \
1753                         source, "prog"; \
1754                         action, STATE_SET "default" 0.0; \
1755                         target, "wdb/"#_pos"/text"; \
1756                         target, "wdb/"#_pos"/text_wday"; \
1757                 } \
1758                 program { name, "wdb/"#_pos"/sunday"; \
1759                         signal, "sunday,"#_pos; \
1760                         source, "prog"; \
1761                         action, STATE_SET "sunday" 0.0; \
1762                         target, "wdb/"#_pos"/text"; \
1763                         target, "wdb/"#_pos"/text_wday"; \
1764                 } \
1765                 program { name, "wdb/"#_pos"/satday"; \
1766                         signal, "satday,"#_pos; \
1767                         source, "prog"; \
1768                         action, STATE_SET "satday" 0.0; \
1769                         target, "wdb/"#_pos"/text"; \
1770                         target, "wdb/"#_pos"/text_wday"; \
1771                 } \
1772                 program { name, "wdb/"#_pos"/set_check"; \
1773                         signal, "check,"#_pos; \
1774                         source, "prog"; \
1775                         action, STATE_SET "checked" 0.0; \
1776                         target, "wdb/"#_pos"/check"; \
1777                 } \
1778                 program { name, "wdb/"#_pos"/unset_check"; \
1779                         signal, "uncheck,"#_pos; \
1780                         source, "prog"; \
1781                         action, STATE_SET "default" 0.0; \
1782                         target, "wdb/"#_pos"/check"; \
1783                 } \
1784                 program { name, "wdb/"#_pos"/expand_up_1"; \
1785                         signal, "set_expand_up_1,"#_pos; \
1786                         source, "prog"; \
1787                         action, STATE_SET "expand_up_1" 0.0; \
1788                         target, "wdb/"#_pos"/base"; \
1789                         target, "wdb/"#_pos"/expand_button"; \
1790                 } \
1791                 program { name, "wdb/"#_pos"/expand_up_2"; \
1792                         signal, "set_expand_up_2,"#_pos; \
1793                         source, "prog"; \
1794                         action, STATE_SET "expand_up_2" 0.0; \
1795                         target, "wdb/"#_pos"/base"; \
1796                         target, "wdb/"#_pos"/expand_button"; \
1797                 } \
1798                 program { name, "wdb/"#_pos"/expand_hide_up"; \
1799                         signal, "set_expand_hide_up,"#_pos; \
1800                         source, "prog"; \
1801                         action, STATE_SET "expand_hide_up" 0.0; \
1802                         target, "wdb/"#_pos"/base"; \
1803                         target, "wdb/"#_pos"/expand_button"; \
1804                 } \
1805                 program { name, "wdb/"#_pos"/expand_hide_down"; \
1806                         signal, "set_expand_hide_down,"#_pos; \
1807                         source, "prog"; \
1808                         action, STATE_SET "expand_hide_down" 0.0; \
1809                         target, "wdb/"#_pos"/base"; \
1810                         target, "wdb/"#_pos"/expand_button"; \
1811                 } \
1812                 program { name, "wdb/"#_pos"/expand_default"; \
1813                         signal, "set_expand_default,"#_pos; \
1814                         source, "prog"; \
1815                         action, STATE_SET "default" 0.0; \
1816                         target, "wdb/"#_pos"/base"; \
1817                         target, "wdb/"#_pos"/expand_button"; \
1818                 } \
1819                 program { name, "wdb/"#_pos"/more_clicked"; \
1820                         signal, "mouse,clicked,1"; \
1821                         source, "wdb/"#_pos"/title"; \
1822                         action, SIGNAL_EMIT #_pos "more"; \
1823                 } \
1824                 program { name, "wdb/"#_pos"/today_focus"; \
1825                         signal, "focus,"#_pos",today"; \
1826                         source, "prog"; \
1827                         action, STATE_SET "default" 0.1; \
1828                         target, "wdb/"#_pos"/title"; \
1829                 } \
1830                 program { name, "wdb/"#_pos"/today_unfocus"; \
1831                         signal, "unfocus,"#_pos",today"; \
1832                         source, "prog"; \
1833                         action, STATE_SET "default" 0.0; \
1834                         target, "wdb/"#_pos"/title"; \
1835                 } \
1836                 program { name, "wdb/"#_pos"/focus"; \
1837                         signal, "focus,"#_pos",wday"; \
1838                         source, "prog"; \
1839                         action, STATE_SET "default" 0.1; \
1840                         target, "wdb/"#_pos"/title_bg"; \
1841                 } \
1842                 program { name, "wdb/"#_pos"/unfocus"; \
1843                         signal, "unfocus,"#_pos",wday"; \
1844                         source, "prog"; \
1845                         action, STATE_SET "default" 0.0; \
1846                         target, "wdb/"#_pos"/title_bg"; \
1847                 } \
1848                 program { name, "wdb/"#_pos"/show_more"; \
1849                         signal, "show,"#_pos",more"; \
1850                         source, "prog"; \
1851                         action, STATE_SET "default" 0.0; \
1852                         target, "wdb/"#_pos"/more"; \
1853                 } \
1854                 program { name, "wdb/"#_pos"/hide_more"; \
1855                         signal, "hide,"#_pos",more"; \
1856                         source, "prog"; \
1857                         action, STATE_SET "default" 0.1; \
1858                         target, "wdb/"#_pos"/more"; \
1859                 } \
1860
1861 #define LS_WDB_S_S(_pos) \
1862         part { name, "wdb/"#_pos"/base"; \
1863                 type, RECT; \
1864                 description { \
1865                         state, "default" 0.0; \
1866                         rel1 { \
1867                                 relative, (2 / 3) \
1868                                         LS_WEEK_DAY_WDB_S_S_Y_TOP_COORD_RATIO(_pos); \
1869                                 to, "wdb/base"; \
1870                         } \
1871                         rel2 { \
1872                                 relative, (1) \
1873                                         LS_WEEK_DAY_WDB_S_S_Y_BOTTOM_COORD_RATIO(_pos); \
1874                                 to, "wdb/base"; \
1875                         } \
1876                         color, 246 246 246 255; \
1877                 } \
1878                 description { \
1879                         state: "expand_hide_up" 0.0; \
1880                         inherit: "default" 0.0; \
1881                         rel1 { \
1882                                 relative, (2 / 3)  0 ;\
1883                                 offset, 0 (_pos - 4)*LS_WEEK_DAY_TITLE_HEIGHT; \
1884                                 to, "wdb/base"; \
1885                         } \
1886                         rel2 { \
1887                                 relative, 1 0 ;\
1888                                 offset, 0 LS_WEEK_DAY_TITLE_HEIGHT*2; \
1889                                 to, "wdb/base"; \
1890                         } \
1891                 } \
1892                 description { \
1893                         state: "expand_hide_down" 0.0; \
1894                         inherit: "default" 0.0; \
1895                         rel1 { \
1896                                 relative, (2 / 3) 1 ;\
1897                                 offset, 0  (_pos - 7)*LS_WEEK_DAY_TITLE_HEIGHT; \
1898                                 to, "wdb/base"; \
1899                         } \
1900                         rel2 { \
1901                                 relative, (1) 1;\
1902                                 offset, 0 (6 -_pos)*LS_WEEK_DAY_TITLE_HEIGHT; \
1903                                 to, "wdb/base"; \
1904                         } \
1905                 } \
1906                 description { \
1907                         state, "expand_up_1" 0.0; \
1908                         rel1 { \
1909                                 relative, (2 / 3) 0 ;\
1910                                 offset, 0 ((_pos - 4)*LS_WEEK_DAY_TITLE_HEIGHT); \
1911                                 to, "wdb/base"; \
1912                         } \
1913                         rel2 { \
1914                                 relative, (1) 1 ;\
1915                                 offset, 0 (_pos - 6)*LS_WEEK_DAY_TITLE_HEIGHT; \
1916                                 to, "wdb/base"; \
1917                         } \
1918                         color, 255 255 255 255;\
1919                 } \
1920                 description { \
1921                         state, "expand_up_2" 0.0; \
1922                         rel1 { \
1923                                 relative, (2 / 3) 0 ;\
1924                                 offset, 0 (_pos - 4)*LS_WEEK_DAY_TITLE_HEIGHT; \
1925                                 to, "wdb/base"; \
1926                         } \
1927                         rel2 { \
1928                                 relative, (1) 1 ;\
1929                                 offset, 0 (_pos - 6)*LS_WEEK_DAY_TITLE_HEIGHT; \
1930                                 to, "wdb/base"; \
1931                         } \
1932                         color, 255 255 255 255;\
1933                 } \
1934         } \
1935         part { name, "wdb/"#_pos"/sel"; \
1936                 mouse_events, 0; \
1937                 description { \
1938                         state, "default" 0.0; \
1939                         rel1.to, "wdb/"#_pos"/base"; \
1940                         rel2 { \
1941                                 offset, 0 0; \
1942                                 to, "wdb/"#_pos"/base"; \
1943                         } \
1944                         visible, 0; \
1945                 } \
1946                 description { \
1947                         state, "selected" 0.0; \
1948                         inherit, "default" 0.0; \
1949                         visible, 1; \
1950                 } \
1951         } \
1952         part { name, "wdb/"#_pos"/bg"; \
1953                 mouse_events, 0; \
1954                 description { \
1955                         state, "default" 0.0; \
1956                         rel1.to, "wdb/"#_pos"/base"; \
1957                         rel2.to, "wdb/"#_pos"/base"; \
1958                         visible, 0; \
1959                 } \
1960                 description { \
1961                         state, "down" 0.0; \
1962                         inherit, "default" 0.0; \
1963                         visible, 1; \
1964                 } \
1965         } \
1966         part { name, "wdb/"#_pos"/title"; \
1967                 type, RECT; \
1968                 scale, 1; \
1969                 mouse_events, 1; \
1970                 description { \
1971                         state, "default" 0.0; \
1972                         rel1.to, "wdb/"#_pos"/base"; \
1973                         rel2 { \
1974                                 relative, 1.0 0.0; \
1975                                 offset, 0 LS_WEEK_DAY_TITLE_HEIGHT; \
1976                                 to, "wdb/"#_pos"/base"; \
1977                         } \
1978                         align, 0.5 0.0; \
1979                         color, COLOR_OF_WEEK_ITEM_TITLE; \
1980                 } \
1981                 description { \
1982                         state, "default" 0.1; \
1983                         inherit, "default" 0.0; \
1984                         color, COLOR_OF_TODAY_FOR_WEEK_CAL; \
1985                 } \
1986         } \
1987         part { name, "wdb/"#_pos"/title_bg"; \
1988                 type, RECT; \
1989                 scale, 1; \
1990                 mouse_events, 0; \
1991                 description { \
1992                         state, "default" 0.0; \
1993                         rel1.to, "wdb/"#_pos"/base"; \
1994                         rel2 { \
1995                                 relative, 1.0 0.0; \
1996                                 offset, 0 LS_WEEK_DAY_TITLE_HEIGHT; \
1997                                 to, "wdb/"#_pos"/base"; \
1998                         } \
1999                         align, 0.5 0.0; \
2000                         color, COLOR_OF_WEEK_ITEM_TITLE; \
2001                         visible, 0; \
2002                 } \
2003                 description { \
2004                         state, "default" 0.1; \
2005                         inherit, "default" 0.0; \
2006                         color, 182 221 241 255; \
2007                         visible, 1; \
2008                 } \
2009         } \
2010         part { name, "wdb/"#_pos"/text"; \
2011                 type, TEXT; \
2012                 scale, 1; \
2013                 mouse_events, 0; \
2014                 description { \
2015                         state, "default" 0.0; \
2016                         rel1 { \
2017                                 relative, (LS_WEEK_ITEM_RIGHT_OFFSET/LS_WEEK_ITEM_WIDTH) 0.0; \
2018                                 to, "wdb/"#_pos"/title"; \
2019                         } \
2020                         rel2 { \
2021                                 relative, ((LS_WEEK_ITEM_RIGHT_OFFSET+LS_WEEK_ITEM_TITLE_DAY_WIDTH)/LS_WEEK_ITEM_WIDTH) 1.0; \
2022                                 to, "wdb/"#_pos"/title"; \
2023                         } \
2024                         text { \
2025                                 font, "SLP:style=Medium"; \
2026                                 size, 40; \
2027                                 align, 0.0 1.0; \
2028                         } \
2029                         color, 56 57 58 255; \
2030                 } \
2031                 description { \
2032                         state, "sunday" 0.0; \
2033                         inherit, "default" 0.0; \
2034                         color, 200 0 0 255; \
2035                 } \
2036                 description { \
2037                         state, "satday" 0.0; \
2038                         inherit, "default" 0.0; \
2039                         color, 0 0 200 255; \
2040                 } \
2041         } \
2042         part { name, "wdb/"#_pos"/text_wday"; \
2043                 type, TEXT; \
2044                 scale, 1; \
2045                 mouse_events, 0; \
2046                 description { \
2047                         state, "default" 0.0; \
2048                         rel1 { \
2049                                 relative, ((LS_WEEK_ITEM_RIGHT_OFFSET+LS_WEEK_ITEM_TITLE_DAY_WIDTH+LS_WEEK_ITEM_TITLE_WDAY_OFFSET)/LS_WEEK_ITEM_WIDTH) (((LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_TITLE_DAY_HEIGHT)/2+LS_WEEK_ITEM_TITLE_DAY_HEIGHT-LS_WEEK_ITEM_TITLE_WDAY_HEIGHT)/LS_WEEK_ITEM_HEIGHT); \
2050                                 to, "wdb/"#_pos"/title"; \
2051                         } \
2052                         rel2 { \
2053                                 relative, 0.5 ((LS_WEEK_ITEM_HEIGHT-(LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_TITLE_DAY_HEIGHT)/2)/LS_WEEK_ITEM_HEIGHT); \
2054                                 to, "wdb/"#_pos"/title"; \
2055                         } \
2056                         text { \
2057                                 font, "SLP:style=Medium"; \
2058                                 size, 19; \
2059                                 align, 0.0 1.0; \
2060                         } \
2061                         color, 56 57 58 255; \
2062                 } \
2063                 description { \
2064                         state, "sunday" 0.0; \
2065                         inherit, "default" 0.0; \
2066                         color, 200 0 0 255; \
2067                 } \
2068                 description { \
2069                         state, "satday" 0.0; \
2070                         inherit, "default" 0.0; \
2071                         color, 0 0 200 255; \
2072                 } \
2073         } \
2074         part { name, "wdb/"#_pos"/more"; \
2075                 type, TEXT; \
2076                 scale, 1; \
2077                 mouse_events, 1; \
2078                 description { \
2079                         state, "default" 0.0; \
2080                         rel1 { \
2081                                 relative, (LS_WEEK_ITEM_WIDTH-LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH-LS_WEEK_ITEM_RIGHT_OFFSET-LS_WEEK_ITEM_RIGHT_OFFSET-LS_WEEK_ITEM_TITLE_MORE_WIDTH)/LS_WEEK_ITEM_WIDTH 0.0; \
2082                                 to, "wdb/"#_pos"/title"; \
2083                         } \
2084                         rel2 { \
2085                                 relative, 0.0 1.0; \
2086                                 to_x, "wdb/"#_pos"/expand_button"; \
2087                                 to_y, "wdb/"#_pos"/title"; \
2088                         } \
2089                         text { \
2090                                 font, "SLP:style=Medium"; \
2091                                 size, 26; \
2092                                 align, 0.0 0.5; \
2093                                 text, "..."; \
2094                         } \
2095                         color, 7 180 211 255; \
2096                 } \
2097         } \
2098         part { name, "wdb/"#_pos"/expand_button"; \
2099                 mouse_events, 0; \
2100                 description { \
2101                         state, "default" 0.0; \
2102                         rel1 { \
2103                                 relative, ((LS_WEEK_ITEM_WIDTH - LS_WEEK_ITEM_RIGHT_OFFSET - LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH)/LS_WEEK_ITEM_WIDTH) ((LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2/LS_WEEK_ITEM_HEIGHT); \
2104                                 to, "wdb/"#_pos"/title"; \
2105                         } \
2106                         rel2 { \
2107                                 relative,  ((LS_WEEK_ITEM_WIDTH - LS_WEEK_ITEM_RIGHT_OFFSET)/LS_WEEK_ITEM_WIDTH) ((LS_WEEK_ITEM_HEIGHT-((LS_WEEK_ITEM_HEIGHT - LS_WEEK_ITEM_EXPAND_BUTTON_WIDTH)/2))/LS_WEEK_ITEM_HEIGHT); \
2108                                 to, "wdb/"#_pos"/title"; \
2109                         } \
2110                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
2111                         visible, 1; \
2112                 } \
2113                 description { \
2114                         state, "expand_up_1" 0.0; \
2115                         inherit, "default" 0.0; \
2116                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
2117                 } \
2118                 description { \
2119                         state, "expand_up_2" 0.0; \
2120                         inherit, "default" 0.0; \
2121                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_CLOSE; \
2122                 } \
2123                 description { \
2124                         state, "expand_hide_up" 0.0; \
2125                         inherit, "default" 0.0; \
2126                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
2127                 } \
2128                 description { \
2129                         state, "expand_hide_down" 0.0; \
2130                         inherit, "default" 0.0; \
2131                         image.normal, CALENDAR_WEEK_EXPAND_BUTTON_OPEN; \
2132                 } \
2133         } \
2134         part { name, "wdb/"#_pos"/check"; \
2135                 mouse_events, 0; \
2136                 scale, 1; \
2137                 description { \
2138                         state, "default" 0.0; \
2139                         rel1 { \
2140                                 relative, 0.1 0.5; \
2141                                 to, "wdb/"#_pos"/text"; \
2142                         } \
2143                         rel2 { \
2144                                 relative, 0.1 0.5; \
2145                                 to, "wdb/"#_pos"/text"; \
2146                         } \
2147                         min, 44 44; \
2148                         fixed, 1 1; \
2149                         align, 0.5 0.5; \
2150                         visible, 0; \
2151                 } \
2152                 description { \
2153                         state, "checked" 0.0; \
2154                         inherit, "default" 0.0; \
2155                         visible, 1; \
2156                 } \
2157         } \
2158         part { name, "wdb/"#_pos"/disable"; \
2159                 type, SWALLOW; \
2160                 description { \
2161                         state, "default" 0.0; \
2162                         rel1.to, "wdb/"#_pos"/base"; \
2163                         rel2.to, "wdb/"#_pos"/base"; \
2164                 } \
2165         } \
2166         part { name, "wdb/"#_pos"/sw"; \
2167                 type, SWALLOW; \
2168                 mouse_events, 1; \
2169                 description { \
2170                         state, "default" 0.0; \
2171                         rel1 { \
2172                                 relative, 0.0 1.0; \
2173                                 to_x, "wdb/"#_pos"/base"; \
2174                                 to_y, "wdb/"#_pos"/title"; \
2175                         } \
2176                         rel2.to, "wdb/"#_pos"/base"; \
2177                         fixed, 1 1; \
2178                 } \
2179         } \
2180         programs { \
2181                 program { name, "wdb/"#_pos"/down"; \
2182                         signal, "mouse,down,1"; \
2183                         source, "wdb/"#_pos"/base"; \
2184                         action, STATE_SET "down" 0.0; \
2185                         target, "wdb/"#_pos"/bg"; \
2186                 } \
2187                 program { name, "wdb/"#_pos"/mouse_down"; \
2188                         signal, "mouse,down,1"; \
2189                         source, "wdb/"#_pos"/base"; \
2190                         action, SIGNAL_EMIT #_pos "down"; \
2191                 } \
2192                 program { name, "wdb/"#_pos"/up"; \
2193                         signal, "mouse,up,1"; \
2194                         source, "wdb/"#_pos"/base"; \
2195                         action, STATE_SET "default" 0.0; \
2196                         target, "wdb/"#_pos"/bg"; \
2197                 } \
2198                 program { name, "wdb/"#_pos"/click"; \
2199                         signal, "mouse,clicked,1"; \
2200                         source, "wdb/"#_pos"/base"; \
2201                         action, SIGNAL_EMIT #_pos "cal"; \
2202                 } \
2203                 program { name, "wdb/"#_pos"/weekday"; \
2204                         signal, "weekday,"#_pos; \
2205                         source, "prog"; \
2206                         action, STATE_SET "default" 0.0; \
2207                         target, "wdb/"#_pos"/text"; \
2208                         target, "wdb/"#_pos"/text_wday"; \
2209                 } \
2210                 program { name, "wdb/"#_pos"/sunday"; \
2211                         signal, "sunday,"#_pos; \
2212                         source, "prog"; \
2213                         action, STATE_SET "sunday" 0.0; \
2214                         target, "wdb/"#_pos"/text"; \
2215                         target, "wdb/"#_pos"/text_wday"; \
2216                 } \
2217                 program { name, "wdb/"#_pos"/satday"; \
2218                         signal, "satday,"#_pos; \
2219                         source, "prog"; \
2220                         action, STATE_SET "satday" 0.0; \
2221                         target, "wdb/"#_pos"/text"; \
2222                         target, "wdb/"#_pos"/text_wday"; \
2223                 } \
2224                 program { name, "wdb/"#_pos"/select"; \
2225                         signal, "select,"#_pos; \
2226                         source, "prog"; \
2227                         action, STATE_SET "selected" 0.0; \
2228                         target, "wdb/"#_pos"/sel"; \
2229                 } \
2230                 program { name, "wdb/"#_pos"/unselect"; \
2231                         signal, "unselect,"#_pos; \
2232                         source, "prog"; \
2233                         action, STATE_SET "default" 0.0; \
2234                         target, "wdb/"#_pos"/sel"; \
2235                 } \
2236                 program { name, "wdb/"#_pos"/set_check"; \
2237                         signal, "check,"#_pos; \
2238                         source, "prog"; \
2239                         action, STATE_SET "checked" 0.0; \
2240                         target, "wdb/"#_pos"/check"; \
2241                 } \
2242                 program { name, "wdb/"#_pos"/unset_check"; \
2243                         signal, "uncheck,"#_pos; \
2244                         source, "prog"; \
2245                         action, STATE_SET "default" 0.0; \
2246                         target, "wdb/"#_pos"/check"; \
2247                 } \
2248                 program { name, "wdb/"#_pos"/expand_up_1"; \
2249                         signal, "set_expand_up_1,"#_pos; \
2250                         source, "prog"; \
2251                         action, STATE_SET "expand_up_1" 0.0; \
2252                         target, "wdb/"#_pos"/base"; \
2253                         target, "wdb/"#_pos"/expand_button"; \
2254                 } \
2255                 program { name, "wdb/"#_pos"/expand_up_2"; \
2256                         signal, "set_expand_up_2,"#_pos; \
2257                         source, "prog"; \
2258                         action, STATE_SET "expand_up_2" 0.0; \
2259                         target, "wdb/"#_pos"/base"; \
2260                         target, "wdb/"#_pos"/expand_button"; \
2261                 } \
2262                 program { name, "wdb/"#_pos"/expand_hide_up"; \
2263                         signal, "set_expand_hide_up,"#_pos; \
2264                         source, "prog"; \
2265                         action, STATE_SET "expand_hide_up" 0.0; \
2266                         target, "wdb/"#_pos"/base"; \
2267                         target, "wdb/"#_pos"/expand_button"; \
2268                 } \
2269                 program { name, "wdb/"#_pos"/expand_hide_down"; \
2270                         signal, "set_expand_hide_down,"#_pos; \
2271                         source, "prog"; \
2272                         action, STATE_SET "expand_hide_down" 0.0; \
2273                         target, "wdb/"#_pos"/base"; \
2274                         target, "wdb/"#_pos"/expand_button"; \
2275                 } \
2276                 program { name, "wdb/"#_pos"/expand_default"; \
2277                         signal, "set_expand_default,"#_pos; \
2278                         source, "prog"; \
2279                         action, STATE_SET "default" 0.0; \
2280                         target, "wdb/"#_pos"/base"; \
2281                         target, "wdb/"#_pos"/expand_button"; \
2282                 } \
2283                 program { name, "wdb/"#_pos"/more_clicked"; \
2284                         signal, "mouse,clicked,1"; \
2285                         source, "wdb/"#_pos"/title"; \
2286                         action, SIGNAL_EMIT #_pos "more"; \
2287                 } \
2288                 program { name, "wdb/"#_pos"/today_focus"; \
2289                         signal, "focus,"#_pos",today"; \
2290                         source, "prog"; \
2291                         action, STATE_SET "default" 0.1; \
2292                         target, "wdb/"#_pos"/title"; \
2293                 } \
2294                 program { name, "wdb/"#_pos"/today_unfocus"; \
2295                         signal, "unfocus,"#_pos",today"; \
2296                         source, "prog"; \
2297                         action, STATE_SET "default" 0.0; \
2298                         target, "wdb/"#_pos"/title"; \
2299                 } \
2300                 program { name, "wdb/"#_pos"/focus"; \
2301                         signal, "focus,"#_pos",wday"; \
2302                         source, "prog"; \
2303                         action, STATE_SET "default" 0.1; \
2304                         target, "wdb/"#_pos"/title_bg"; \
2305                 } \
2306                 program { name, "wdb/"#_pos"/unfocus"; \
2307                         signal, "unfocus,"#_pos",wday"; \
2308                         source, "prog"; \
2309                         action, STATE_SET "default" 0.0; \
2310                         target, "wdb/"#_pos"/title_bg"; \
2311                 } \
2312                 program { name, "wdb/"#_pos"/show_more"; \
2313                         signal, "show,"#_pos",more"; \
2314                         source, "prog"; \
2315                         action, STATE_SET "default" 0.0; \
2316                         target, "wdb/"#_pos"/more"; \
2317                 } \
2318                 program { name, "wdb/"#_pos"/hide_more"; \
2319                         signal, "hide,"#_pos",more"; \
2320                         source, "prog"; \
2321                         action, STATE_SET "default" 0.1; \
2322                         target, "wdb/"#_pos"/more"; \
2323                 } \
2324         }
2325
2326 #define LEFT_WDB_S_EXPAND_DESC(_pos)\
2327                 description { \
2328                         state: "expand_hide_up" 0.0; \
2329                         inherit: "default" 0.0; \
2330                         rel1 { \
2331                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
2332                                         0; \
2333                                 offset, 0 (_pos/2)*WEEK_DAY_TITLE_HEIGHT; \
2334                                 to, "wdb/base"; \
2335                         } \
2336                         rel2 { \
2337                                 relative, 0 \
2338                                         0; \
2339                                 offset, 0 (_pos/2 + 1)*WEEK_DAY_TITLE_HEIGHT; \
2340                                 to_x: "wdb/line/vert";\
2341                                 to_y: "wdb/base"; \
2342                         } \
2343                 } \
2344                 description { \
2345                         state: "expand_hide_down" 0.0; \
2346                         inherit: "default" 0.0; \
2347                         rel1 { \
2348                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
2349                                         1; \
2350                                 offset, 0 (_pos/2-3)*WEEK_DAY_TITLE_HEIGHT; \
2351                                 to, "wdb/base"; \
2352                         } \
2353                         rel2 { \
2354                                 relative, 0 \
2355                                         1; \
2356                                 offset, 0 ((_pos-4)/2)*WEEK_DAY_TITLE_HEIGHT; \
2357                                 to_x: "wdb/line/vert";\
2358                                 to_y: "wdb/base"; \
2359                         } \
2360                 } \
2361                 description { \
2362                         state: "expand_down" 0.0; \
2363                         inherit: "default" 0.0; \
2364                         rel1 { \
2365                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
2366                                         WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos); \
2367                                 to, "wdb/base"; \
2368                         } \
2369                         rel2 { \
2370                                 relative, 0 \
2371                                         1; \
2372                                 offset, 0  ((_pos-4)/2)*WEEK_DAY_TITLE_HEIGHT; \
2373                                 to_x: "wdb/line/vert";\
2374                                 to_y: "wdb/base"; \
2375                         } \
2376                         color, 255 255 255 255;\
2377                 } \
2378                 description { \
2379                         state: "expand_up" 0.0; \
2380                         inherit: "default" 0.0; \
2381                         rel1 { \
2382                                 relative, WEEK_DAY_X_LEFT_COORD_RATIO(_pos) \
2383                                         0; \
2384                                 offset, 0 (_pos/2)*WEEK_DAY_TITLE_HEIGHT; \
2385                                 to, "wdb/base"; \
2386                         } \
2387                         rel2 { \
2388                                 relative, 0 \
2389                                         1; \
2390                                 offset, 0 ((_pos-4)/2)*WEEK_DAY_TITLE_HEIGHT;\
2391                                 to_x: "wdb/line/vert";\
2392                                 to_y: "wdb/base"; \
2393                         } \
2394                         color, 255 255 255 255;\
2395                 }
2396
2397 #define RIGHT_WDB_B_EXPAND_DESC(_pos)\
2398                 description { \
2399                         state: "expand_hide_up" 0.0; \
2400                         inherit: "default" 0.0; \
2401                         rel1 { \
2402                                 relative, 1 \
2403                                         0; \
2404                                 offset, 0 ((_pos-1)/2)*WEEK_DAY_TITLE_HEIGHT; \
2405                                 to_x: "wdb/line/vert";\
2406                                 to_y: "wdb/base"; \
2407                         } \
2408                         rel2 { \
2409                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
2410                                         0; \
2411                                 offset, 0 ((_pos+1)/2)*WEEK_DAY_TITLE_HEIGHT; \
2412                                 to, "wdb/base"; \
2413                         } \
2414                 } \
2415                 description { \
2416                         state: "expand_hide_down" 0.0; \
2417                         inherit: "default" 0.0; \
2418                         rel1 { \
2419                                 relative, 1 \
2420                                         1; \
2421                                 offset, 0 -WEEK_DAY_TITLE_HEIGHT*_pos; \
2422                                 to_x: "wdb/line/vert";\
2423                                 to_y: "wdb/base"; \
2424                         } \
2425                         rel2 { \
2426                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
2427                                         1; \
2428                                 offset, 0 (((_pos-1)/2)-3)*WEEK_DAY_TITLE_HEIGHT; \
2429                                 to, "wdb/base"; \
2430                         } \
2431                 } \
2432                 description { \
2433                         state: "expand_down" 0.0; \
2434                         inherit: "default" 0.0; \
2435                         rel1 { \
2436                                 relative, 1 \
2437                                         WEEK_DAY_WDB_S_Y_TOP_COORD_RATIO(_pos); \
2438                                 to_x: "wdb/line/vert";\
2439                                 to_y: "wdb/base"; \
2440                         } \
2441                         rel2 { \
2442                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
2443                                         1; \
2444                                 offset, 0 (((_pos-3)/2)-2)*WEEK_DAY_TITLE_HEIGHT; \
2445                                 to, "wdb/base"; \
2446                         } \
2447                         color, 255 255 255 255;\
2448                 } \
2449                 description { \
2450                         state: "expand_up" 0.0; \
2451                         inherit: "default" 0.0; \
2452                         rel1 { \
2453                                 relative, 1 \
2454                                         0; \
2455                                 offset, 0 (_pos/3)*WEEK_DAY_TITLE_HEIGHT; \
2456                                 to_x: "wdb/line/vert";\
2457                                 to_y: "wdb/base"; \
2458                         } \
2459                         rel2 { \
2460                                 relative, WEEK_DAY_X_RIGHT_COORD_RATIO(_pos) \
2461                                         1; \
2462                                 offset, 0 (_pos/3-3)*WEEK_DAY_TITLE_HEIGHT; \
2463                                 to, "wdb/base"; \
2464                         } \
2465                         color, 255 255 255 255;\
2466                 } \
2467
2468 #define RIGHT_WDB_B_B_EXPAND_DESC(_pos) \
2469                 description { \
2470                         state: "expand_hide_up" 0.0; \
2471                         inherit: "default" 0.0; \
2472                         rel1 { \
2473                                 relative, 1 \
2474                                         0; \
2475                                 offset, 0 (_pos-3)*WEEK_DAY_TITLE_HEIGHT; \
2476                                 to_x: "wdb/line/vert";\
2477                                 to_y: "wdb/base"; \
2478                         } \
2479                         rel2 { \
2480                                 relative, (1) \
2481                                         0; \
2482                                 offset, 0 (_pos-2)*WEEK_DAY_TITLE_HEIGHT; \
2483                                 to, "wdb/base"; \
2484                         } \
2485                 } \
2486                 description { \
2487                         state: "expand_hide_down" 0.0; \
2488                         inherit: "default" 0.0; \
2489                         rel1 { \
2490                                 relative, 1 \
2491                                         1; \
2492                                 offset, 0 (_pos-7)*WEEK_DAY_TITLE_HEIGHT; \
2493                                 to_x: "wdb/line/vert";\
2494                                 to_y: "wdb/base"; \
2495                         } \
2496                         rel2 { \
2497                                 relative, (1) \
2498                                         1; \
2499                                 offset, 0 (_pos-6)*WEEK_DAY_TITLE_HEIGHT; \
2500                                 to, "wdb/base"; \
2501                         } \
2502                 } \
2503                 description { \
2504                         state, "expand_up_1" 0.0; \
2505                         rel1 { \
2506                                 relative, 1 \
2507                                         0; \
2508                                 offset, 0 2*WEEK_DAY_TITLE_HEIGHT; \
2509                                 to_x: "wdb/line/vert";\
2510                                 to_y: "wdb/base"; \
2511                         } \
2512                         rel2 { \
2513                                 relative, (1) \
2514                                         1; \
2515                                 offset, 0 -WEEK_DAY_TITLE_HEIGHT; \
2516                                 to, "wdb/base"; \
2517                         } \
2518                 } \
2519                 description { \
2520                         state, "expand_up_2" 0.0; \
2521                         rel1 { \
2522                                 relative, 1 \
2523                                         0; \
2524                                 offset, 0 3*WEEK_DAY_TITLE_HEIGHT; \
2525                                 to_x: "wdb/line/vert";\
2526                                 to_y: "wdb/base"; \
2527                         } \
2528                         rel2 { \
2529                                 relative, (1) \
2530                                         1; \
2531                                 to, "wdb/base"; \
2532                         } \
2533                 } \
2534
2535
2536 group { name, "main/week/small";
2537
2538         images {
2539                 image, "P01_week_view_icon_open.png" COMP;
2540                 image, "P01_week_view_icon_close.png" COMP;
2541         }
2542
2543         parts {
2544                 part { name, "base";
2545                         type, RECT;
2546                         description {
2547                                 state, "default" 0.0;
2548                                 color, 0 0 0 0;
2549                         }
2550                 }
2551
2552                 part { name, "wdb/base";
2553                         type, RECT;
2554                         description {
2555                                 state, "default" 0.0;
2556                                 rel1.to, "base";
2557                                 rel2.to, "base";
2558                                 color, 0 0 0 0;
2559                         }
2560                 }
2561
2562                 part { name, "wdb/line/vert";
2563                         type, RECT;
2564                         description {
2565                                 state, "default" 0.0;
2566                                 min: 2 0;
2567                         fixed: 1 0;
2568                                 rel1 {
2569                                   relative: 1/2 0.0;
2570                                   to_x: "base";
2571                                   to_y: "base";
2572                                }
2573                                 rel2 {
2574                                    relative: 1/2 1.0;
2575                                   to_x: "base";
2576                                   to_y: "base";
2577                                 }
2578                                 align: 0.0 0.0;
2579                                 color, 171 171 171 255;
2580                         }
2581                 }
2582
2583                 part { name, "wdb/0/base";
2584                         type, RECT;
2585                         description {
2586                                 state, "default" 0.0;
2587                                 rel1 {
2588                                         relative: 0.0 0.0;
2589                                         to_x: "base";
2590                                         to_y: "base";
2591                                 }
2592                                 rel2 {
2593                                         relative: 0.0 1/3;
2594                                         to_x: "wdb/line/vert";
2595                                         to_y: "base";
2596                                 }
2597                                 color, 246 246 246 255;
2598                         }
2599                         LEFT_WDB_S_EXPAND_DESC(0)
2600                 }
2601
2602                 LEFT_WDB_S_TITLE(0)
2603                 WDB_S(0)
2604
2605                 part { name, "wdb/1/base";
2606                         type, RECT;
2607                         description {
2608                                 state, "default" 0.0;
2609                                 rel1 {
2610                                         relative: 1.0 0.0;
2611                                         to_x: "wdb/line/vert";
2612                                         to_y: "base";
2613                                 }
2614                                 rel2 {
2615                                         relative: 1 1/3;
2616                                         to, "base";
2617                                 }
2618                                 color, 246 246 246 255;
2619                         }
2620                         RIGHT_WDB_B_EXPAND_DESC(1)
2621                 }
2622
2623                 RIGHT_WDB_S_TITLE(1)
2624                 WDB_S(1)
2625
2626                 part { name, "wdb/2/base";
2627                         type, RECT;
2628                         description {
2629                                 state, "default" 0.0;
2630                                 rel1 {
2631                                         relative: 0.0 1.0;
2632                                         to, "wdb/0/base";
2633                                 }
2634                                 rel2 {
2635                                         relative: 0.0 2/3;
2636                                         to_x: "wdb/line/vert";
2637                                         to_y: "base";
2638                                 }
2639                                 color, 246 246 246 255;
2640                         }
2641                         LEFT_WDB_S_EXPAND_DESC(2)
2642                 }
2643
2644                 LEFT_WDB_S_TITLE(2)
2645                 WDB_S(2)
2646
2647                 part { name, "wdb/3/base";
2648                         type, RECT;
2649                         description {
2650                                 state, "default" 0.0;
2651                                 rel1 {
2652                                         relative: 1.0 1.0;
2653                                         to_x: "wdb/line/vert";
2654                                         to_y: "wdb/1/base";
2655                                 }
2656                                 rel2 {
2657                                         relative: 1 2/3;
2658                                         to_x: "base";
2659                                         to_y: "base";
2660                                 }
2661                                 color, 246 246 246 255;
2662                         }
2663                         RIGHT_WDB_B_EXPAND_DESC(3)
2664                 }
2665
2666                 RIGHT_WDB_S_TITLE(3)
2667                 WDB_S(3)
2668
2669                 part { name, "wdb/4/base";
2670                         type, RECT;
2671                         description {
2672                                 state, "default" 0.0;
2673                                 rel1 {
2674                                         relative: 0.0 1.0;
2675                                         to, wdb/2/base;
2676                                 }
2677                                 rel2 {
2678                                         relative: 0 1;
2679                                         to_x: "wdb/line/vert";
2680                                         to_y: "base";
2681                                 }
2682                                 color, 246 246 246 255;
2683                         }
2684                         LEFT_WDB_S_EXPAND_DESC(4)
2685                 }
2686
2687                 LEFT_WDB_S_TITLE(4)
2688                 WDB_S(4)
2689
2690                 part { name, "wdb/5/base";
2691                         type, RECT;
2692                         description {
2693                                 state, "default" 0.0;
2694                                 rel1 {
2695                                         relative: 1.0 1.0;
2696                                         to_x: "wdb/line/vert";
2697                                         to_y: "wdb/3/base";
2698                                 }
2699                                 rel2 {
2700                                         relative: 1 1;
2701                                         offset, 0 145;
2702                                         to_x: "base";
2703                                         to_y: "wdb/3/base";
2704                                 }
2705                                 align: 0.0 0.0;
2706                                 color, 246 246 246 255;
2707                         }
2708                         RIGHT_WDB_B_B_EXPAND_DESC(5)
2709                 }
2710
2711                 RIGHT_WDB_S_S_TITLE(5)
2712
2713                 WDB_S_S(5)
2714
2715                 part { name, "gap";
2716                         type, RECT;
2717                         description {
2718                                 state, "default" 0.0;
2719                                 rel1 {
2720                                         relative: 1.0 1.0;
2721                                         to_x: "wdb/line/vert";
2722                                         to_y: "wdb/5/base";
2723                                 }
2724                                 rel2 {
2725                                         relative: 1.0 1.0;
2726                                         offset, 0 8;
2727                                         to_x: "base";
2728                                         to_y: "wdb/5/base";
2729                                 }
2730                                 color, 246 246 246 255;
2731                         }
2732                 }
2733
2734                 part { name, "wdb/6/base";
2735                         type, RECT;
2736                         description {
2737                                 state, "default" 0.0;
2738                                 rel1 {
2739                                         relative: 1.0 1.0;
2740                                         to_x: "wdb/line/vert";
2741                                         to_y: "gap";
2742                                 }
2743                                 rel2 {
2744                                         relative: 1 1;
2745                                         to_x: "base";
2746                                         to_y: "base";
2747                                 }
2748                                 align: 0.0 0.0;
2749                                 color, 246 246 246 255;
2750                         }
2751                         RIGHT_WDB_B_B_EXPAND_DESC(6)
2752                 }
2753
2754                 RIGHT_WDB_S_S_TITLE(6)
2755                 WDB_S_S(6)
2756         }
2757         programs {
2758                 WBS_S_PROGRAMS(0)
2759                 WBS_S_PROGRAMS(1)
2760                 WBS_S_PROGRAMS(2)
2761                 WBS_S_PROGRAMS(3)
2762                 WBS_S_PROGRAMS(4)
2763                 WBS_S_S_PROGRAMS(5)
2764                 WBS_S_S_PROGRAMS(6)
2765         }
2766 }
2767
2768 group { name, "landscape/main/week/small";
2769
2770         images {
2771                 image, "57_calendar_week_view_press.png" COMP;
2772                 image, "57_calendar_week_view_bg.png" COMP;
2773                 image, "calendar_selected.png" COMP;
2774                 image, "P01_week_view_icon_open.png" COMP;
2775                 image, "P01_week_view_icon_close.png" COMP;
2776         }
2777
2778         parts {
2779                 part { name, "base";
2780                         type, RECT;
2781                         description {
2782                                 state, "default" 0.0;
2783                                 color, 0 0 0 0;
2784                         }
2785                 }
2786
2787                 part { name, "wdb/base";
2788                         type, RECT;
2789                         description {
2790                                 state, "default" 0.0;
2791                                 rel1 {
2792                                         offset, 0 1;
2793                                         to, "base";
2794                                 }
2795                                 rel2.to, "base";
2796                                 color, 0 0 0 0;
2797                         }
2798                 }
2799
2800                 LS_WDB_S( 0) LS_WDB_S( 1) LS_WDB_S( 2)
2801                 LS_WDB_S( 3) LS_WDB_S( 4) LS_WDB_S_S( 5)
2802                 LS_WDB_S_S( 6)
2803
2804                 part { name, "wdb/line/top";
2805                         type, RECT;
2806                         description {
2807                                 state, "default" 0.0;
2808                                 rel1.to, "base";
2809                                 rel2 {
2810                                         relative, 1.0 0.0;
2811                                         offset, -1 0;
2812                                         to, "base";
2813                                 }
2814                                 color, 195 192 179 255;
2815                         }
2816                 }
2817
2818                 part { name, "wdb/line/vertical/1";
2819                         type, RECT;
2820                         description {
2821                                 state, "default" 0.0;
2822                                 rel1 {
2823                                         relative, 1/3 0.0;
2824                                         to, "base";
2825                                 }
2826                                 rel2 {
2827                                         relative, 1/3 1.0;
2828                                         offset, 0 -1;
2829                                         to, "base";
2830                                 }
2831                                 color, 195 192 179 255;
2832                         }
2833                 }
2834                 part { name, "wdb/line/vertical/2";
2835                         type, RECT;
2836                         description {
2837                                 state, "default" 0.0;
2838                                 rel1 {
2839                                         relative, 2/3 0.0;
2840                                         to, "base";
2841                                 }
2842                                 rel2 {
2843                                         relative, 2/3 1.0;
2844                                         offset, 0 -1;
2845                                         to, "base";
2846                                 }
2847                                 color, 195 192 179 255;
2848                         }
2849                 }
2850         }
2851 }
2852