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

Re: [css3-background] fallback color on background-image

From: fantasai <fantasai.lists@inkedblade.net>
Date: Fri, 20 Feb 2009 12:20:56 -0800
Message-ID: <499F10A8.1000402@inkedblade.net>
To: "L. David Baron" <dbaron@dbaron.org>
CC: CSS WG <www-style@w3.org>
L. David Baron wrote:
>
> The fallback isn't about syntax.  It's about using the fallback
> color when images fail to load or have not loaded yet.
> 
> For example, if you have a background image that has some
> transparency, but if the image isn't supported, is still loading, or
> the user has images disabled, you'd prefer a color rather than
> having complete transparency, you can do:
> 
>   background-image: whatever;
>   background-color: transparent blue;
> 
> (I'd also note that I preferred the old syntax, where the fallback
> was separated by a '/', but the group decided it was more important
> to use the '/' to separate 'background-size' in the 'background'
> shorthand than to separate the colors.  I don't care enough to
> object.)

You raised a parsing issue with using slash for both, and disambiguation
is less necessary for color (where always specifying both is a possible
workaround) than it is for background-size (where it would be mixed up
with background-position). So we dropped the slash for color. I don't
like it either, I also preferred the old syntax. If you have a better
solution than dropping the slash, or if you, as an implementor, think
keeping the slash is worth the parsing complexity, then let's reopen
this and resolve it another way. The current resolution was uncomfortable
enough to me that I left it marked in the draft.

~fantasai
Received on Friday, 20 February 2009 20:21:36 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:16 GMT