W3C home > Mailing lists > Public > www-style@w3.org > January 2018

CSS Backgrounds and Borders Module Level 3 and border-attachment

From: Dennis Heuer <einz@verschwendbare-verweise.seinswende.de>
Date: Thu, 11 Jan 2018 23:01:30 +0100
To: www-style@w3.org
Message-Id: <20180111230130.316de81e706ce12a758d2354@verschwendbare-verweise.seinswende.de>
Hello

It's embarrassing that authors hide communication behind third-party
systems, expecting participants to create accounts...

CSS Backgrounds and Borders Module Level 3:

border-attachment:

The description for 'scroll' seems to tell the opposite. The term
'local' is non-interpretable, even after reading the description. From
my point of view, the description for 'scroll' should be the
description for 'fixed', and the description for 'fixed' should be the
description only for e.g. the body or the html element. There are
further logical issues to how the current definitions work (see below):

fixed

The background is fixed with regard to the viewport. In paged media
where there is no viewport, a fixed background is fixed with respect to
the page box and therefore replicated on every page. Note that there is
only one viewport per view. Even if an element has a scrolling
mechanism (see the overflow property [CSS2]), a fixed background
doesn’t move with the element.

local

The background is fixed with regard to the element’s contents: if the
element has a scrolling mechanism, the background scrolls with the
element’s contents, and the background painting area and background
positioning area are relative to the scrollable area of the element
rather than to the border framing them. Because the scrollable area
does not include the border area, for scrollable elements the
border-box value of background-clip may be treated the same as
padding-box.

scroll

The background is fixed with regard to the element itself and does not
scroll with its contents. (It is effectively attached to the element’s
border.) 


The logical issues are that some terms are not only used somewhat loose
but also in a way that not all feasible options are available. To me it
also seems that some decision should rather be done with the property
background-position:

* 'fixed' should only refer to an element, and the 'viewport' or 'page'
should be addressed as an element (like body or html)

* 'scroll' should just work like 'fixed' but scroll the background-image
with the element's inners

* 'local' works like 'scroll' but restricts the background-image to
the padding-box. This causes two issues: The first is the non-telling
name not showing any relation to the issue. The second is that 'local'
can not serve the image 'fixed'. I'd prefer optional two keywords like
'border' and 'content' instead of 'local'. Nevertheless, I'd prefer to
use the property background-position for this.

The property background-position is another candidate that shows a very
focused, use-case based definition. I'd treat the background like a div
and allow a more flexible configuration: A property like background-area
would either take single padding-values and stretch to the borders for
the missing values. Or it takes certain keywords for known areas, like
border, margin-box, padding-box or content or similar. The property
background-position can then align a single non-repeated image in that
area, if wished so. The floating is already covered with
background-repeat.

Regards,
---------------------------------------------------------------------
Dennis Heuer
einz@verschwendbare-verweise.seinswende.de
Received on Friday, 12 January 2018 08:24:46 UTC

This archive was generated by hypermail 2.3.1 : Friday, 12 January 2018 08:25:04 UTC