W3C home > Mailing lists > Public > www-style@w3.org > December 2008

Re: [css3-background] number of layers should consider background-origin and background-clip

From: fantasai <fantasai.lists@inkedblade.net>
Date: Mon, 08 Dec 2008 18:04:09 -0800
Message-ID: <493DD219.9060007@inkedblade.net>
To: "L. David Baron" <dbaron@dbaron.org>
CC: www-style@w3.org

L. David Baron wrote:
> http://dev.w3.org/csswg/css3-background/#layering says that the
> number of background layers considers the background-image,
> backgroundrepeat, background-size, and background-position
> properties, but not the background-clip and background-origin
> properties.
> I think the number of layers should consider either (a) all six
> properties or (b) only background-image.
> Furthermore, the statement about interpreting each of the properties
> as though it has a certain number of values should refer to all six
> properties.

I agree it should be all or nothing. And I don't think the layerable
properties should be listed in a separate section, I think each property
should say on its own that it affects the layering.

But really, I think it makes the most sense for only background-image
to create layers. Because I can totally see something like this happening:

.classA {
   background: url(topleft.png) top left,
               url(bottomright.png) bottom right,
               url(topright.png) top right,
               url(bottomleft.png) bottom left;
   background-repeat: no-repeat;
   ... other stuff ...

#foo {
   background-color: silver;
   background-image: url(matte.png);
   background-repeat: repeat;

<div class="classA" id="foo" will have four layers. Authors aren't going
to realize that the background shorthand is the only thing that will
reliably unset all the layers.

Also, if we add another layerable background-foo property in the future
it can break rendering on existing pages through this phenomenon: an
explicit list of all background properties will no longer reset the layers.

Received on Tuesday, 9 December 2008 02:04:53 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:42 UTC