W3C home > Mailing lists > Public > www-style@w3.org > October 2009

Comments on gradient syntax proposal

From: L. David Baron <dbaron@dbaron.org>
Date: Tue, 27 Oct 2009 09:24:03 -0700
To: www-style@w3.org
Cc: "Tab Atkins Jr." <jackalmage@gmail.com>
Message-ID: <20091027162403.GA30169@pickering.dbaron.org>
Here are a few minor comments on the current version gradient syntax
proposal at http://www.xanthir.com/:4bhipd .  (It might be good to
have a dated version archived at some point, though.)  I noticed
these issues while reviewing the patch to implement this proposal in

# if relevant, the angle is normalized to within the range
# [0,360deg)
(occurs once for linear gradients and once for radial)

Normalizing angles is a bad idea for animation.  It makes it
impossible to animate angles through a sweep that includes pointing
left.  I think you should just remove mention of normalization.

# Between two color-stops, the colors are interpolated as SVG
# gradients.

The spec ought to say explicitly whether this means that the
'color-interpolation' property applies.  See

In the description of radial gradients:

# The image is constructed by creating an infinite canvas and
# painting it with concentric copies of the ending-shape, with the
# color of the painted shape being the color of the gradient-line
# where the two intersect.

Saying that ellipses are concentric doesn't define what they are.  I
think what you want to say is that they are concentric *and* the
ratio of their major axis to minor axis is constant.  (You could,
for example, have concentric ellipses that are confocal, but I
really don't think that's what's desired here.)

# If <shape> is ellipse and <size> is closest-side, the
# gradient-shape is an ellipse sized so that it exactly meets the
# two sides of the box closest to its center.

This needs to say that it's the closest horizontal side and the
closest vertical side, since the two closest sides might be


L. David Baron                                 http://dbaron.org/
Mozilla Corporation                       http://www.mozilla.com/
Received on Tuesday, 27 October 2009 16:24:35 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 11 February 2015 12:34:30 UTC