From: Ben C on
On 2010-04-23, dorayme <dorayme(a)> wrote:
> In article <slrnhsll24.4kc.spamspam(a)bowser.marioworld>,
> Ben C <spamspam(a)spam.eggs> wrote:
>> On 2010-04-18, dorayme <dorayme(a)> wrote:
>> [...]
>> > But, anyway, I was not talking a paragraph, a div can simply have
>> > inline text in it and this is content but rather different to the
>> > way a paragraph is content, in the latter case it is a proper
>> > named immediate descendant, a child and any further elements
>> > inside the paragraph would be grandchildren. The line boxes of
>> > text inside the p which is inside the div, well, I have never
>> > been sure whether to think of these as technically
>> > "grandchildren" of the div or "children" of p.
> The key words here are "whether to think of these as". I don't
> like to think of them as these. It is possible I will have no
> choice though. Time will tell.

I think Lego bricks or something is a better mental model for all this
stuff than anonymous bastards.

For example one problem they're trying to address is inline content
inside something that's expecting block content.

This is like two bricks that don't fit together. So you find a brick the
top of which will stick to the inside of a block and the bottom of which
will stick to something that's inline. So now you can insert this brick
between your container and your content and make it all hold together.
That adaptor brick is the "anonymous block".

The anonymous table family elements all work along the same lines-- you
can't just put a table cell in a table, it needs a row, and so on.

All the rules in 17.2ff pretty much boil down to:

1. If your brick doesn't fit, first try removing any adaptor bricks you
already put there one by one until it does.
2. If that didn't work, rummage around for some different adaptor
bricks. Use as few as you can get away with.

>> If you've got:
>> <div><p>text</p></div>
>> There is an anonymous inline box around "text". You've got a block box
>> for the div, whose child is a block box for the p, whose child is an
>> anonymous box with the text in it.
>> The anonymous box with text in it "generates" a line box in the way that
>> inline boxes generally generate line boxes.
>> If you've got:
>> <div>more<p>text</p></div>
>> Then you get an anonymous block around "more", and another anonymous
>> inline inside that anonymous block for the text.
> So that the inline anonymous box around "more" is a sibling of p,
> and an auntkle of "text", and div has more children than it may
> realise and even a grandchild that might surprise it greatly?


> In other words it is not just elements, at least not named elements,
> that get to be in the family tree eh? Sounds like a cookie scheme to
> me, a bit like someone dreaming up reasons for someone's foot or shoe
> to be part of the family. I don't like it and want to know the name
> and address of the person responsible for this far fetched idea.

First  |  Prev  | 
Pages: 1 2 3 4 5 6
Prev: Going Live
Next: Q: How do I create a "snaking-column"?