Re: W3C 'CSS3 module: Color' Working Draft dated 19th February 2002

Chris Lilley wrote:
 >
 > You misunderstand.
 >
 > 1) compound values can already be animated

With each axis of the compound value "animatable" individually?

e.g. background-position's left coordinate and background-position's top
coordinate can be animated distinctly?


 > 2) there is already an animate Color element, specifically to animate color
 >
 > 3) animations can be chained, and can repeat
 >
 > 4) try expressing an animation where the color goes from blue to green, over
 > a period of five seconds, for times; and where the transparency of the text
 > fades from 0 to 1 over a period of three seconds and repeats indefinitely
 >  a) using animations of separate properties
 >  b) using an animation of a single property
 > Both can be done, but one is a whole lot easier to author and to understand.

In any well designed animation API both would be as easy as each other.

Take the 'clip' property for instance. It takes a rect() value consisting of
four individual coordinates. Try expressing an animation where the vertical 
clipping goes from top to bottom, over a period of five seconds, four times; and 
where the horizontal clipping of the box goes from 0 to 10 pixels over a period 
of three seconds and repeats indefinitely,
    a) using animations of separate properties
    b) using an animation of a single property

The first can't be done, since it is only one property. The second had better be 
just as easy to author and understand as the first would be. If it is not, then 
that is a serious flaw in the animation API.


 >> DOM manipulation is not a problem.  DOM2Style already allows for
 >> manipulation of the red value in an rgb() value, so manipulation of an alpha
 >> value in an rgba() value logically follows.
 >
 > Granted. Provided the inefficiencies of string slicing are not a drawback,
 > this can be done.

You misunderstood. The CSSOM API has ways to access each individual component -- 
red, green, and blue -- as *individual numbers*. Not through hacky inefficient 
string parsing. Through a dedicated interface.

    http://www.w3.org/TR/DOM-Level-2-Style/css.html#CSS-RGBColor

-- 
Ian Hickson
``The inability of a user agent to implement part of this specification due to
the limitations of a particular device (e.g., non interactive user agents will
probably not implement dynamic pseudo-classes because they make no sense
without interactivity) does not imply non-conformance.'' -- Selectors, Sec13

Received on Thursday, 28 March 2002 00:46:42 UTC