raster pushed a commit to branch feature/themes/flat.

http://git.enlightenment.org/core/efl.git/commit/?id=44fb635c38d2f80e7e4df12ee96bb78ea79ab50c

commit 44fb635c38d2f80e7e4df12ee96bb78ea79ab50c
Author: Carsten Haitzler (Rasterman) <[email protected]>
Date:   Sat Feb 8 23:17:01 2020 +0000

    TH - clock
---
 data/elementary/themes/edc/elm/clock.edc | 197 ++++++++++++-------------------
 1 file changed, 74 insertions(+), 123 deletions(-)

diff --git a/data/elementary/themes/edc/elm/clock.edc 
b/data/elementary/themes/edc/elm/clock.edc
index 43072a65d1..05fcfc4baa 100644
--- a/data/elementary/themes/edc/elm/clock.edc
+++ b/data/elementary/themes/edc/elm/clock.edc
@@ -1,17 +1,23 @@
+#define IC(_NAME, _ICON) \
+set { name: _NAME; \
+image {image: _ICON"-060.png" COMP; size: 31 31 60000 60000; } \
+image {image: _ICON"-030.png" COMP; size: 16 16    30    30; } \
+image {image: _ICON"-015.png" COMP; size:  0  0    15    15; } \
+}
+IC("ic-arrow-u", "arrow-u")
+IC("ic-arrow-d", "arrow-d")
+
 group { name: "elm/clock/flipdigit/default";
-   images.image: "O/digit_na.png" COMP;
-   images.image: "O/digit_0.png" COMP;
-   images.image: "O/digit_1.png" COMP;
-   images.image: "O/digit_2.png" COMP;
-   images.image: "O/digit_3.png" COMP;
-   images.image: "O/digit_4.png" COMP;
-   images.image: "O/digit_5.png" COMP;
-   images.image: "O/digit_6.png" COMP;
-   images.image: "O/digit_7.png" COMP;
-   images.image: "O/digit_8.png" COMP;
-   images.image: "O/digit_9.png" COMP;
-   images.image: "icon_arrow_up.png" COMP;
-   images.image: "icon_arrow_down.png" COMP;
+   images.image: "digit_0.png" COMP;
+   images.image: "digit_1.png" COMP;
+   images.image: "digit_2.png" COMP;
+   images.image: "digit_3.png" COMP;
+   images.image: "digit_4.png" COMP;
+   images.image: "digit_5.png" COMP;
+   images.image: "digit_6.png" COMP;
+   images.image: "digit_7.png" COMP;
+   images.image: "digit_8.png" COMP;
+   images.image: "digit_9.png" COMP;
    script {
       public v0_cur, v0_lock, v0_next;
 
@@ -36,51 +42,39 @@ group { name: "elm/clock/flipdigit/default";
             set_int(v0_cur, value);
             set_int(v0_lock, 1);
             snprintf(buf, 10, "%i", get_int(v0_cur));
-            set_state(PART:"O/digit", buf, 0.0);
+            set_state(PART:"digit", buf, 0.0);
             anim(1.0, "animator1", 1);
          }
       }
    }
    parts {
-      part { name: "O/digit_bg";
-         scale: 1;
-         description { state: "default" 0.0;
-            rel1.to: "O/digit";
-            rel2.to: "O/digit";
-            image.normal: "O/digit_na.png";
-            color: 255 255 255 128;
-         }
-      }
-      part { name: "b";
-         type: RECT;
+      part { name: "b"; type: RECT;
          scale: 1;
-         mouse_events: 1;
          description { state: "default" 0.0;
             visible: 0;
             rel1.relative: 0.0 0.5;
             color: 0 0 0 0;
+            min: 20 20;
          }
          description { state: "visible" 0.0;
             inherit: "default" 0.0;
             visible: 1;
          }
       }
-      part { name: "t";
-         type: RECT;
+      part { name: "t"; type: RECT;
          scale: 1;
-         mouse_events: 1;
          description { state: "default" 0.0;
             visible: 0;
             rel2.relative: 1.0 0.5;
             color: 0 0 0 0;
+            min: 20 20;
          }
          description { state: "visible" 0.0;
             inherit: "default" 0.0;
             visible: 1;
          }
       }
-      part { name: "O/digit";
-         mouse_events: 0;
+      part { name: "digit"; mouse_events: 0;
          scale: 1;
          description { state: "default" 0.0;
             rel1.to_y: "atop";
@@ -88,12 +82,13 @@ group { name: "elm/clock/flipdigit/default";
             rel2.to_y: "abot";
             rel2.relative: 1.0 0.0;
             aspect: (52/72) (52/72); aspect_preference: BOTH;
-            image.normal: "O/digit_0.png";
+            image.normal: "digit_0.png";
+            color: 160 160 160 255;
          }
 #define DIGIT_DESC(_DIGIT) \
    description { state: _DIGIT 0.0; \
       inherit: "default" 0.0; \
-      image.normal: "O/digit_"_DIGIT".png"; \
+      image.normal: "digit_"_DIGIT".png"; \
    }
          DIGIT_DESC("0")
          DIGIT_DESC("1")
@@ -107,8 +102,7 @@ group { name: "elm/clock/flipdigit/default";
          DIGIT_DESC("9")
       }
 #undef DIGIT_DESC
-      part { name: "atop";
-         mouse_events: 0;
+      part { name: "atop"; mouse_events: 0;
          scale: 1;
          description { state: "default" 0.0;
             visible: 0;
@@ -116,23 +110,23 @@ group { name: "elm/clock/flipdigit/default";
             rel2.relative: 1.0 0.2;
             align: 0.5 0.0;
             aspect: 1 1; aspect_preference: BOTH;
-            image.normal: "icon_arrow_up.png";
+            image.normal: "ic-arrow-u";
+            color: 160 160 160 255;
          }
          description { state: "visible" 0.0;
             inherit: "default" 0.0;
             visible: 1;
          }
       }
-      part { name: "abot";
-         mouse_events: 0;
-         scale: 1;
+      part { name: "abot"; mouse_events: 0; scale: 1;
          description { state: "default" 0.0;
             visible: 0;
             rel1.relative: 0.0 0.8;
             rel2.relative: 1.0 1.0;
             align: 0.5 0.0;
             aspect: 1 1; aspect_preference: BOTH;
-            image.normal: "icon_arrow_down.png";
+            image.normal: "ic-arrow-d";
+            color: 160 160 160 255;
          }
          description { state: "visible" 0.0;
             inherit: "default" 0.0;
@@ -142,8 +136,7 @@ group { name: "elm/clock/flipdigit/default";
       part { name: "access.t";
          type: RECT;
          description { state: "default" 0.0;
-            rel1.to: "t";
-            rel2.to: "t";
+            rel.to: "t";
             color: 0 0 0 0;
             visible: 0;
          }
@@ -155,8 +148,7 @@ group { name: "elm/clock/flipdigit/default";
       part { name: "access.b";
          type: RECT;
          description { state: "default" 0.0;
-            rel1.to: "b";
-            rel2.to: "b";
+            rel.to: "b";
             color: 0 0 0 0;
             visible: 0;
          }
@@ -167,85 +159,59 @@ group { name: "elm/clock/flipdigit/default";
       }
    }
    programs {
-      program { name: "load";
-         signal: "load";
-         source: "";
+      program { signal: "load"; source: "";
          script {
             set_int(v0_cur, 0);
             set_int(v0_lock, 0);
             set_int(v0_next, -1);
          }
       }
-      program { name: "edit_on";
-         signal: "elm,state,edit,on";
-         source: "elm";
+      program { signal: "elm,state,edit,on"; source: "elm";
          action: STATE_SET "visible" 0.0;
          target: "atop";
          target: "abot";
          target: "t";
          target: "b";
       }
-      program { name: "edit_off";
-         signal: "elm,state,edit,off";
-         source: "elm";
+      program { signal: "elm,state,edit,off"; source: "elm";
          action: STATE_SET "default" 0.0;
          target: "atop";
          target: "abot";
          target: "t";
          target: "b";
       }
-      program { name: "up";
-         signal: "mouse,down,1";
-         source: "t";
+      program { signal: "mouse,down,1"; source: "t";
          action: SIGNAL_EMIT "elm,action,up,start" "elm";
       }
-      program { name: "up,stop";
-         signal: "mouse,up,1";
-         source: "t";
+      program { signal: "mouse,up,1"; source: "t";
          action: SIGNAL_EMIT "elm,action,up,stop" "elm";
       }
-      program { name: "down";
-         signal: "mouse,down,1";
-         source: "b";
+      program { signal: "mouse,down,1"; source: "b";
          action: SIGNAL_EMIT "elm,action,down,start" "elm";
       }
-      program { name: "down,stop";
-         signal: "mouse,up,1";
-         source: "b";
+      program { signal: "mouse,up,1"; source: "b";
          action: SIGNAL_EMIT "elm,action,down,stop" "elm";
       }
-      program { name: "access_edit_on";
-         signal: "elm,state,access,edit,on";
-         source: "elm";
+      program { signal: "elm,state,access,edit,on"; source: "elm";
          action: STATE_SET "visible" 0.0;
          target: "access.t";
          target: "access.b";
       }
-      program { name: "access_edit_off";
-         signal: "elm,state,access,edit,off";
-         source: "elm";
+      program { signal: "elm,state,access,edit,off"; source: "elm";
          action: STATE_SET "default" 0.0;
          target: "access.t";
          target: "access.b";
       }
-      program { name: "access,up";
-         signal: "mouse,down,1";
-         source: "access.t";
+      program { signal: "mouse,down,1"; source: "access.t";
          action: SIGNAL_EMIT "elm,action,up,start" "elm";
       }
-      program { name: "access,up,stop";
-         signal: "mouse,up,1";
-         source: "access.t";
+      program { signal: "mouse,up,1"; source: "access.t";
          action: SIGNAL_EMIT "elm,action,up,stop" "elm";
       }
-      program { name: "access,down";
-         signal: "mouse,down,1";
-         source: "access.b";
+      program { signal: "mouse,down,1"; source: "access.b";
          action: SIGNAL_EMIT "elm,action,down,start" "elm";
       }
-      program { name: "access,down,stop";
-         signal: "mouse,up,1";
-         source: "access.b";
+      program { signal: "mouse,up,1"; source: "access.b";
          action: SIGNAL_EMIT "elm,action,down,stop" "elm";
       }
    }
@@ -254,30 +220,19 @@ group { name: "elm/clock/flipdigit/default";
 
 group { name: "elm/clock/flipampm/default";
    inherit: "elm/clock/flipdigit/default";
-   images.image: "O/digit_nm.png" COMP;
-   images.image: "O/digit_am.png" COMP;
-   images.image: "O/digit_pm.png" COMP;
+   images.image: "digit_am.png" COMP;
+   images.image: "digit_pm.png" COMP;
    parts {
-      part { name: "O/digit_bg";
+      part { name: "digit"; mouse_events: 0;
          scale: 1;
          description { state: "default" 0.0;
-            rel1.to: "O/digit";
-            rel2.to: "O/digit";
-            image.normal: "O/digit_nm.png";
-            color: 255 255 255 128;
-         }
-      }
-      part { name: "O/digit";
-         mouse_events: 0;
-         scale: 1;
-         description { state: "default" 0.0;   
             aspect: (48/31) (48/31); aspect_preference: BOTH;
-            image.normal: "O/digit_am.png";
+            image.normal: "digit_am.png";
          }
 #define DIGIT_DESC(_DIGIT, _AMPM) \
    description { state: _DIGIT 0.0; \
       inherit: "default" 0.0; \
-      image.normal: "O/digit_"_AMPM".png"; \
+      image.normal: "digit_"_AMPM".png"; \
    }
          DIGIT_DESC("0", "am")
          DIGIT_DESC("1", "pm")
@@ -296,8 +251,8 @@ group { name: "elm/clock/flipampm/default";
    }
 
 #define HOLE_PART(_NAME, _R1X, _R1Y, _R2X, _R2Y, _AX, _AY, _OX, _OY, _W, _H) \
-   part { name: _NAME; \
-         mouse_events: 0; \
+   part { name: _NAME; mouse_events: 0; \
+         scale: 1; \
          description { state: "default" 0.0; \
             rel1.relative: _R1X _R1Y; \
             rel1.offset: _OX _OY; \
@@ -307,21 +262,22 @@ group { name: "elm/clock/flipampm/default";
             min: _W _H; \
             max: _W _H; \
             fixed: 1 1; \
-            image.normal: "hole_tiny.png"; \
+            image.normal: "digit_sep.png"; \
+            color: 160 160 160 255; \
          } \
       }
 
 group { name: "elm/clock/base-all/default";
-   images.image: "hole_tiny.png" COMP;
+   images.image: "digit_sep.png" COMP;
    parts {
       SWALLOW_PART("d0", 0.0, 0.0, 0.125, 1.0)
       SWALLOW_PART("d1", 0.125, 0.0, 0.25, 1.0)
-      HOLE_PART("c0t", 0.25, 0.5, 0.3125, 0.5, 0.5, 1.0, 0, -2, 4, 4)
-      HOLE_PART("c0b", 0.25, 0.5, 0.3125, 0.5, 0.5, 0.0, 0, 1, 4, 4)
+      HOLE_PART("c0t", 0.25, 0.5, 0.3125, 0.5, 0.5, 1.0, 0, -2, 2, 2)
+      HOLE_PART("c0b", 0.25, 0.5, 0.3125, 0.5, 0.5, 0.0, 0, 1, 2, 2)
       SWALLOW_PART("d2", 0.3125, 0.0, 0.4375, 1.0)
       SWALLOW_PART("d3", 0.4375, 0.0, 0.5625, 1.0)
-      HOLE_PART("c1t", 0.5625, 0.5, 0.625, 0.5, 0.5, 1.0, 0, -2, 4, 4)
-      HOLE_PART("c1b", 0.5625, 0.5, 0.625, 0.5, 0.5, 0.0, 0, 1, 4, 4)
+      HOLE_PART("c1t", 0.5625, 0.5, 0.625, 0.5, 0.5, 1.0, 0, -2, 2, 2)
+      HOLE_PART("c1b", 0.5625, 0.5, 0.625, 0.5, 0.5, 0.0, 0, 1, 2, 2)
       SWALLOW_PART("d4", 0.625, 0.0, 0.75, 1.0)
       SWALLOW_PART("d5", 0.75, 0.0, 0.875, 1.0)
       SWALLOW_PART("ampm", 0.875, 0.0, 1.0, 1.0)
@@ -332,12 +288,12 @@ group { name: "elm/clock/base-seconds/default";
    parts {
       SWALLOW_PART("d0", 0.0, 0.0, 0.142857143, 1.0)
       SWALLOW_PART("d1", 0.142857143, 0.0, 0.285714286, 1.0)
-      HOLE_PART("c0t", 0.285714286, 0.5, 0.357142857, 0.5, 0.5, 1.0, 0, -2, 4, 
4)
-      HOLE_PART("c0b", 0.285714286, 0.5, 0.357142857, 0.5, 0.5, 0.0, 0, 1, 4, 
4)
+      HOLE_PART("c0t", 0.285714286, 0.5, 0.357142857, 0.5, 0.5, 1.0, 0, -2, 2, 
2)
+      HOLE_PART("c0b", 0.285714286, 0.5, 0.357142857, 0.5, 0.5, 0.0, 0, 1, 2, 
2)
       SWALLOW_PART("d2", 0.357142857, 0.0, 0.5, 1.0)
       SWALLOW_PART("d3", 0.5, 0.0, 0.642857143, 1.0)
-      HOLE_PART("c1t", 0.642857143, 0.5, 0.714285714, 0.5, 0.5, 1.0, 0, -2, 4, 
4)
-      HOLE_PART("c1b", 0.642857143, 0.5, 0.714285714, 0.5, 0.5, 0.0, 0, 1, 4, 
4)
+      HOLE_PART("c1t", 0.642857143, 0.5, 0.714285714, 0.5, 0.5, 1.0, 0, -2, 2, 
2)
+      HOLE_PART("c1b", 0.642857143, 0.5, 0.714285714, 0.5, 0.5, 0.0, 0, 1, 2, 
2)
       SWALLOW_PART("d4", 0.714285714, 0.0, 0.857142857, 1.0)
       SWALLOW_PART("d5", 0.857142857, 0.0, 1.0, 1.0)
    }
@@ -348,8 +304,8 @@ group { name: "elm/clock/base-am_pm/default";
    parts {
       SWALLOW_PART("d0", 0.0, 0.0, 0.181818182, 1.0)
       SWALLOW_PART("d1", 0.181818182, 0.0, 0.363636364, 1.0)
-      HOLE_PART("c0t", 0.363636364, 0.5, 0.454545455, 0.5, 0.5, 1.0, 0, -2, 4, 
4)
-      HOLE_PART("c0b", 0.363636364, 0.5, 0.454545455, 0.5, 0.5, 0.0, 0, 1, 4, 
4)
+      HOLE_PART("c0t", 0.363636364, 0.5, 0.454545455, 0.5, 0.5, 1.0, 0, -2, 2, 
2)
+      HOLE_PART("c0b", 0.363636364, 0.5, 0.454545455, 0.5, 0.5, 0.0, 0, 1, 2, 
2)
       SWALLOW_PART("d2", 0.454545455, 0.0, 0.636363636, 1.0)
       SWALLOW_PART("d3", 0.636363636, 0.0, 0.818181818, 1.0)
       SWALLOW_PART("ampm", 0.818181818, 0.0, 1.0, 1.0)
@@ -359,8 +315,7 @@ group { name: "elm/clock/base-am_pm/default";
 ///////////////////////////////////////////////////////////////////////////////
 group { name: "elm/clock/base/default";
    parts {
-      part { name: "base";
-         type: RECT;
+      part { name: "base"; type: RECT;
          scale : 1;
          description { state: "default" 0.0;
             color: 0 0 0 0;
@@ -373,21 +328,17 @@ group { name: "elm/clock/base/default";
       }
       SWALLOW_PART("d0", 0.0, 0.0, 0.222222222, 1.0)
       SWALLOW_PART("d1", 0.222222222, 0.0, 0.444444444, 1.0)
-      HOLE_PART("c0t", 0.444444444, 0.5, 0.555555556, 0.5, 0.5, 1.0, 0, -2, 4, 
4)
-      HOLE_PART("c0b", 0.444444444, 0.5, 0.555555556, 0.5, 0.5, 0.0, 0, 1, 4, 
4)
+      HOLE_PART("c0t", 0.444444444, 0.5, 0.555555556, 0.5, 0.5, 1.0, 0, -2, 2, 
2)
+      HOLE_PART("c0b", 0.444444444, 0.5, 0.555555556, 0.5, 0.5, 0.0, 0, 1, 2, 
2)
       SWALLOW_PART("d2", 0.555555556, 0.0, 0.777777778, 1.0)
       SWALLOW_PART("d3", 0.777777778, 0.0, 1.0, 1.0)
    }
    programs {
-      program { name: "access_on";
-         signal: "elm,state,access,on";
-         source: "elm";
+      program { signal: "elm,state,access,on"; source: "elm";
          action: STATE_SET "visible" 0.0;
          target: "base";
       }
-      program { name: "access_off";
-         signal: "elm,state,access,off";
-         source: "elm";
+      program { signal: "elm,state,access,off"; source: "elm";
          action: STATE_SET "default" 0.0;
          target: "base";
       }

-- 


Reply via email to