Re: [css3-backgrounds and borders] shadow color optional?

On 12/24/2010 12:14 AM, Simon Fraser wrote:
> The definition of<shadow>  in CSS3 Backgrounds  and Borders
> <http://www.w3.org/TR/css3-background/#the-box-shadow>, which
> is also reference by text-shadow in CSS3 Text
><http://www.w3.org/TR/2010/WD-css3-text-20101005/#text-shadow0>,
> suggests that the color is optional:
>
> <shadow>  = inset?&&  [<length>{2,4}&&  <color>? ]
>
> (I can't find the meaning of "&&"<http://www.w3.org/TR/css3-syntax/#property-defs>, BTW.)

http://www.w3.org/TR/css3-background/#values
which if you follow the link leads to
http://www.w3.org/TR/CSS21/about.html#value-defs

> What is expected behavior if the color is missing, for both
> text-shadow, and box-shadow? The spec should describe this.

http://www.w3.org/TR/css3-background/#box-shadow

"Omitted lengths are 0; omitted colors are a UA-chosen color."

The omitted colors are a UA-chosen color because that's what
Hyatt requested in place of the previous default of using the
'color' property's value:

http://lists.w3.org/Archives/Member/w3c-css-wg/2003JulSep/0081.html

If Apple wants to provide the rgba coordinates for the default
shadow color provided by CoreGraphics, then I'm sure we can add
that into the spec as a suggestion. I'm a little hesitant to
make it a normative requirement at this point unless the other
implementers on the WG also want it to be normative.

~fantasai

Received on Friday, 24 December 2010 07:46:18 UTC