Re: HTML 5 Authoring Guidelines Proposal the use of the section element and its potential impact on screen reader users

Joshue O Connor wrote:
> 
> First of all apologies to Michael as he did suggest we work on a local
> copy for contributing to the guidelines for authors document but I would
> just like to raise (resurrect) something here.
> 
> According to the document the section element represents "a generic
> document or application section". [1]
> 
> Ok, fine. but when I read the example:
> 
> <body>
>   <h1>Top Level Heading</h1>
>   <section>
>     <h1>Second Level Heading</h1>
>     <section>
>       <h1>Third Level Heading</h1>
>     </section>
>   </section>
> </body
> 
> My first though, is why would anyone want to do this?
> 
> Also (I hope) authors still write the following and produce a conformant
> HTML5 document?
> 
> <body>
>   <h1>Top Level Heading</h1>
>   <p>Some content</p>
>     <h2>Second Level Heading</h2>
>     <p>Some content</p>
>     <h3>Third Level Heading</h3>
>   <p>Some content</p>
> </body>

The idea is that in HTML 5, <section> is not semantically neutral (like <div>), 
but implies an extra depth of heading so the heading structures of both 
documents above are, per spec, identical. Both documents are also conforming. Of 
course, in existing UAs the documents as written will not be interpreted 
identically because existing UAs are unaware of the semantics indicated by 
<section> and other sectioning elements, so the top document will be presented 
with a flat heading structure. Therefore, for compatibility with current tools, 
authors should be advised to mark up the document:

<body>
   <h1>Top Level Heading</h1>
   <section>
     <h2>Second Level Heading</h2>
     <section>
       <h3>Third Level Heading</h3>
     </section>
   </section>
</body>

which is also equivalent to the first two options in a conforming HTML 5 client 
and equivalent to the second in a conforming HTML 4 client. This is why HTML 5 
doesn't adopt the <h> element from XHTML 2, since it wouldn't allow for graceful 
degradation like this.

The authoring guide should be explicit about how to provide markup that degrades 
gracefully, both here and in other places where special consideration must be taken.

In general, HTML 5 defines how to  handle an arbitrary combination of sectioning 
elements and <h1>-<h6>. I have a not-quite-working implementation of this part 
of the spec which I will try to debug soon.

Does this answer your questions, Josh? I'm not sure if I missed your point or not?

-- 
"Eternity's a terrible thought. I mean, where's it all going to end?"
  -- Tom Stoppard, Rosencrantz and Guildenstern are Dead

Received on Tuesday, 27 November 2007 13:07:59 UTC