Re: [CSS Images] syntax for color interpolation hint

(Resending since it didn't go to the group)

On Thu, Oct 2, 2014 at 9:06 PM, Robert O'Callahan <>

> This feature lets authors adjust the interpolation between two color
> stops. The current syntax uses a fake color stop with a position and no
> color as an instruction to interpolate differently between the two real
> stops on either side of it. The position of the color stop is used as a
> parameter to control the interpolation.
> I'm unconvinced this syntax is a good idea. Using a fake color stop for
> this purpose just seems like a hack.

Why is this a hack? It matches how authoring tools present midpoints in
their UI's: they are shown as color stops with no color

> If someone accidentally leaves out a color from a color stop they will
> trigger this feature accidentally. It also means there are edge cases we
> have to check for and reject in the parser, e.g. consecutive fake color
> stops. It's also not particularly extensible; we're consuming this part of
> the syntax (color-less stop) for a particular feature that isn't directly
> related to that syntax.

Why do you think it's not extensible? If we want to support more midpoints
later, we can certainly add support for that by being more permissive

> For an obscure feature like this, can't we afford to be more explicit.
> e.g. attach an interpolation() function to the color-stop before the
> interval we want to change the interpolation of?

That is very confusing because the midpoint applies to the curve of both
color stops.

> Or allow interpolation() values to be interspersed with color stops? Am I
> the only person who has qualms here?

I hope so :-)
FYI this has already landed in WebKit and we're looking into adding it to

Received on Friday, 3 October 2014 16:22:43 UTC