[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [E-devel] edje gradient fill



On Mon, Aug 21, 2006 at 12:16:42AM +0000, jose_ogp@juno.com wrote:
> 
> 	Brian writes:
> 
> > Now, due to the way edje does fills (specify origin and size),
> > you can't easily do this. So, here's what I propose:
> > 
> > Do away with the angle parameter.
> > Use the origin/size to specify the angle AND fill.
> > 
> 	The concept of filling 'from point a to point b' ONLY works
> intuitivly with linear grads, whereas the concept of a fill region
> and angle will work fine with all grad types, and images, and other
> texture notions.
> 
...
> 	I would suggest you add separate gradient types that allow
> you to specify in full their own separate semantics.. eg. have a
> LINEAR_GRADIENT type (apart from the general grad type), and here
> you can put inside its gradient block stuff that is specific to
> whatever semantics you want for this special one -- ie. you'd have
> a new linear_fill block there, or an orientation, or whatever, to
> get the linear gradient to fill in a certain way that may override
> the general fill semantics.
> 	Or add another fill_orientation kind of option in general
> that would work as mentioned -- ie. rotate things from top-left
> to bottom-right.

I realized the inconcistancy when I started implementing this (still
haven't used gradient types other than linear and radial yet -- haven't
felt like trawling evas' code for the params, hint hint ;)

Since this only makes sense for linear grads, i'll probably just add:

gradient.rel1.relative
gradient.rel1.offset
gradient.rel2.relative
gradient.rel2.offset

these will only be used by linear grads, overriding fill.angle,
fill.position.* and fill.size.* if present.

(you can't use these semantics for images without an additional "width
perpendicular to orientation line" parameter, which wouldn't really be
useful in most cases. we'd still need to figure out some way of
specifying "width of image fill = height of part)

So for now, just a gradient specific block that is ignored unless the
gradient type is linear.

rephorm