RE: "non-zero top border" in 8.3.1

> -----Original Message-----
> From: Ian Hickson [mailto:ian@hixie.ch]
> Sent: Tuesday, September 04, 2007 2:31 PM
>
> > 2) when "top border" rule is added, it has to be understood when exactly
> > it happens. Does the previous rule ("If the element's margins are
> > collapsed with its parent's top margin, the top border edge of the box
> > is defined to be the same as the parent's.") still apply? But that's not
> > what would happen if the parent had a top border. But if it didn't
> > apply, expected behavior in test 68 would not be correct.
>
> I don't understand what you're asking. The two sub-bullet points of the
> 6th bullet point of 8.3.1 are mutually exclusive for any one element, but
> the rules are applied to all self-collapsing blocks, so for any one set of
> margins in a set of self-collapsing blocks the rules might apply
> differently for different blocks. Could you elaborate?

It was not obvious to me that the two bullets are mutually exclusive when nested empty boxes are concerned. Second bullet says

    "The position ... is the same as *it would have been* if the element
     had a non-zero top border"

I don't think it necessary means that position of that element's children is also defined to be as if the parent had a top border (because it doesn't actually have it, therefore previous bullet could apply to children). That is what is making this rule confusing.

If however we mean it literally, and to determine the element position we put a top border on it and let it have full effect on everything the actual expected behavior for http://www.hixie.ch/tests/adhoc/css/box/block/margin-collapse/068.html

should be as in attached image, shouldn't it?

Received on Tuesday, 4 September 2007 23:17:48 UTC