W3C home > Mailing lists > Public > public-html@w3.org > April 2011

Re: role="subheading" or role="subtitle" to replace hgroup

From: Ian Hickson <ian@hixie.ch>
Date: Fri, 8 Apr 2011 19:57:44 +0000 (UTC)
To: Maciej Stachowiak <mjs@apple.com>
cc: Bruce Lawson <brucel@opera.com>, HTMLWG WG <public-html@w3.org>, Henri Sivonen <hsivonen@iki.fi>
Message-ID: <Pine.LNX.4.64.1104081955440.25791@ps20323.dreamhostps.com>
On Fri, 8 Apr 2011, Maciej Stachowiak wrote:
> On Apr 8, 2011, at 1:23 AM, Bruce Lawson wrote:
> > On Fri, 08 Apr 2011 09:14:01 +0100, Henri Sivonen <hsivonen@iki.fi> wrote:
> > 
> >> On Thu, 2011-04-07 at 12:34 +0100, Steve Faulkner wrote:
> >>> >2) It would be desirable to have a selector that matches on the
> >>> > outline depth.
> > 
> > [...]
> > 
> >> 
> >> I mean a selector like h1::outline-depth(3) at least for headings
> >> themselves and maybe for all element nodes (like p::outline-depth(2)).
> > 
> > It would be deeply splendid to have such a selector. But how?
> 
> If outline depth is defined solely by number of sectioning element 
> ancestors, then it's pretty simple. But I think HTML5 has a few things 
> that make it more complicates than that (not entirely sure though).

The outline depth for section elements is defined such that only the 
ancestor elements matters, and the outline depth for <h1> specifically 
(since it's the highest rank) is the same. This was an intentional design 
for exactly the reason suggested above (making a pseudo-class reasonable 
to implement for this kind of thing).

The complexity only comes along when you use <h2>-<h6>, but those are 
only really needed for back-compat.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Friday, 8 April 2011 19:58:08 UTC

This archive was generated by hypermail 2.3.1 : Monday, 29 September 2014 09:39:24 UTC