On Mon, 9 Nov 2009 01:24:20 +0100 Carlo Ascani <carlo.r...@gmail.com> said:

luck for you, i saw this one coming a mile off years ago. edje has a feature
precisely for this.

notice with the descriptiosn of states u have that mysetious 0.0 value after
the name and have always wondered "what the hell is that? useless waste of my
typing!". well.. wonder no more.

part { name: "switch";
 description { state: "default" 0.0; image.normal: "im0.png"; }
 description { state: "default" 0.2; image.normal: "im1.png"; }
 description { state: "default" 0.4; image.normal: "im2.png"; }
 description { state: "default" 0.6; image.normal: "im3.png"; }
 description { state: "default" 0.8; image.normal: "im4.png"; }
 description { state: "default" 1.0; image.normal: "im5.png"; }
}

and you know how u can set state:

action: STATE_SET "default" 0.0;

well the 0.0 now can be N where N is 0.0 to 1.0 - you can use ANY value you
like. edje automatically choses the state with that name and the closest VALUE.
you define a set of N values (1 or more - suggestion is to include 0.0 and 1.0
and then more values in between). so set state to "default" 0.13187 and it will
see the closest is 0.2 - and use that.

you can use transitions that make this value go from 0.0 to 1.0 for example and
it will "tween" and choose the states in between as it goes. or should. you can
use embryo (or now lua too) to set the state and programmatically determine the
value to use (from 0.0 to 1.0).

cpufreq in e17's theme uses this for instance :)

> 2009/11/9 Tom Haste <tomha...@gmail.com>
> 
> > Why not use a tween? You'd end up having something like this,
> >
> Cause tween is intended for looping animation, if i have learn correctly.
> I need an animation between two differente images, playing only once at
> time.
> Anyway animations (up and down) work, the problem is in the script that
> should alternate them...
> 
> -- 
> Carlo Ascani
> La politica pratica consiste nell'ignorare i fatti. (Henry Adams)
> C programmers never die. They are just cast into void.
> -------------------------------------
> msn: bradw...@hotmail.it
> cell: 320 2915799
> Visita www.ptondo.it
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
> trial. Simplify your report design, integration and deployment - and focus on 
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
> _______________________________________________
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> 


-- 
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler)    ras...@rasterman.com


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to