Joerg,
This is one of the more complex areas of the spec. It took me some time to work out what it was all for. Arved directed me to an innocuous little statement near the top of 4.2.5 Stacking Constraints. "The intention of the definitions is to identify areas at any level of the tree which have only space between them." The trouble is, that to make sense of all that follows, and of the term "stacking constraint", you need to have read the introduction in 4.3 Spaces and Conditionality, especially in its use of the term "constraint".
I find that thinking of "stacking constraint" as "spaces interaction" or "spaces stacking interaction" clarifies the discussion for me. That's why fences are not defined between siblings (the spaces are outside the padding/borders of each sibling, and so are free to interact), but are defined between a child and the sibling of its parent (because non-zero padding/border on the parent will prevent interaction between the spaces of the child and the parent's sibling.) Similar considerations apply to reference areas.
I am preparing some notes at the moment on data structures that may be useful for both space specifier and keep resolution, based on the notes I posted a few days ago concerning the relationships between blocks, of which keep processing needed to be aware. I hope to post them in the next few days, with the diagrams that help to make sense of all this.
Peter
Arved Sandstrom wrote:
Joerg, it's the diagrams that accompany Section 4.2.5 that make things halfway understandable. They have an diagrammed example of each clause.
There are also some key statements in the first paragraph of 4.2.5 - namely, that the definitions are recursive, and, that the entire point of the definitions is to identify areas that have only spaces between them. So actually I was also half-incorrect, because I spoke too hastily; with respect to the situation with _siblings_ and their space-after/space-before, the borders & padding do _not_ have to have zero width.
Even where borders and padding have non-zero width they may have a conditionality of "discard", in which case under certain conditions they look like they have zero width for space-resolution purposes.