- From: zjopy via GitHub <sysbot+gh@w3.org>
- Date: Fri, 22 May 2020 21:47:15 +0000
- To: public-css-archive@w3.org
zjopy has just created a new issue for https://github.com/w3c/csswg-drafts: == [css-display] Unclear definition of "formatting context" == I find the definition of formatting context in the [spec](https://www.w3.org/TR/css-display-3/#formatting-context) a bit unclear. 1. > A formatting context is the environment into which a set of related boxes are laid out. What is an "environment"? This is one of those typical blanket words. Without giving a definition of environment, this sentence is not saying much. I'll take for now FC as synonym with "box layout", where layout is a visual arrangement. 2. > A box either establishes a new independent formatting context or continues the formatting context of its containing block. So each box establishes a formatting context (defines a layout) for its descendant boxes. This makes sense, since its descendant subtree must be laid out somehow. But what does "continue a formatting context" mean here? How can the nested box tree continue in the identical layout? After all the boxes are visually "inside" the box. Does "continue" rather mean the box establishes a new formatting context of the same type as the one of its containing block? Also I'm not sure if "containing block" is correct here. It's defined in the specific Positioned Layout, so using it for defining more general terms used by all layouts including Positioned Layout is kind of circular. 3. > The type of formatting context established by the box is determined by its inner display type An inner display type is defined for an element, not for a box. The inner display type may even generate multiple boxes with each different formatting contexts, like for [`display: table`](https://www.w3.org/TR/css-display-3/#valdef-display-table). --- It's really hard to make sense of the current spec. Some definitions are even circular, like for example of "inline box" > A non-replaced inline-level box [box that participates in inline formatting context] whose inner display type is `flow`. Ok, same problem to above, a box doesn't have a display type, the associated element does. But let's read on what inner display type `flow` does. > If its outer display type is inline [..], and it is participating in a block or inline formatting context, then it generates an inline box. Ugh. Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5105 using your GitHub account
Received on Friday, 22 May 2020 21:47:17 UTC