Re: separator/seperator Re: About XHTML 2.0

Orion Adrian wrote:

>The issue I have with this approach is that it creates issues with sub-sections.
>
>
>For section to work appropriately, text must be able to be placed in
>the exact section level that it is meant to be placed. This means that
>section can't be used for anything other than creating the overarching
>organization of the document. Any other uses prevents proper styling
>and filtering.
>
>If I wanted only the text from section level 1 to section level 3 I
>don't want two block of text to disappear just because I need to
>seperate them to communicate a perspective shift for example.
>
>Orion Adrian
>
>  
>
In this case, however, your document structure is wrong, not the
semantics of section.

Think about what a separator does: it separates. What does it separate,
though? Does it separate paragraphs? No, that's what starting a new
paragraph does. Does it separate sections? No, that's what starting a
new section does. What is between a section and a paragraph? To stay
with earlier examples, is it a perspective? But isn't a perspective a
lower-priority section? I certainly think so.
A book that has perspective changes might have this format, then:

<section class="chapter">
<h>Chapter 1</h>
<section class="scene">
<section class="perspective">
<p>It was a dark and stormy night. Thick fog hung over the countryside
like carbon dioxide on a film set.</p>
</section>
<section class="perspective">
<p>She hated storms. Hated them with a passion.</p>
</section>
</section>
<section class="scene">
<section class="perspective">
<p>This scene has only one perspective. So what?</p>
</section>
</section>
</section>

Lots of sections there. But it is not wrong, and it completely removes
the need for the separators. Still have styling issues? Change your
stylesheet then.

In fact, the perspective change is a particularly bad example. Let's for
the moment suppose I add my own namespace to XHTML 2, one that only
defines a single attribute, 'perspective', which, applied to a section,
denotes whose viewpoint this is. (Then I use CSS to attach different
fonts to the different characters or different voices in an aural
stylesheet.)
With the section-based layout, I have this:

<section class="perspective" book:perspective="Omniscient">
<p>It was a dark and stormy night. Thick fog hung over the countryside
like carbon dioxide on a film set.</p>
</section>
<section class="perspective" book:perspective="Laura">
<p>She hated storms. Hated them with a passion.</p>
</section>

With the separator-based:

<section class="perspective" book:perspective="Omniscient">
<p>It was a dark and stormy night. Thick fog hung over the countryside
like carbon dioxide on a film set.</p>
<separator/><!-- Where to put that attribute? -->
<p>She hated storms. Hated them with a passion.</p>
<p>Another paragraph.</p>
<p>And another, just to show the impracticability of putting the
attribute on the paragraph tag.</p>
</section>

For your final comment, that you don't want the text to disappear if you
select section levels 1-3 ... obviously you've chosen the wrong section
levels. You want that text, and it's in section level 4. How then can
you complain that you don't get it if you're dismissing level 4?
It seems as though you're trying to fit the document structure to your
preconceived notion of how it should look. That's the wrong approach.
Document structure must be discovered, not created.

Sebastian Redl

Received on Monday, 23 May 2005 16:51:24 UTC