W3C home > Mailing lists > Public > whatwg@whatwg.org > October 2008

[whatwg] Early feedback on header association algorithm

From: Aaron Leventhal <aaronlev@moonset.net>
Date: Wed, 29 Oct 2008 18:43:21 +0100
Message-ID: <4908A0B9.9090705@moonset.net>
1. On this part:
         "If there is a header cell in the table 
<http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#concept-table> 
whose corresponding |th 
<http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-th-element>| 
element has an ID that is equal to the value of id, then assign the 
first such header cell in tree order to the data cell. "
I don't want to implement a special local table only 
getElementByIdInTable. I'd rather have this reworded to something like
"If there is an element in the document with a corresponding ID (via 
getElementById) equal to the value of /id/, and it is a header cell in 
the current table, then assign it to the data cell."

2. The larger part of algorithm is upside down for our needs. I see a 
use case for providing what headers are associated with a cell, but not 
the other way around. Typically an AT will want to know what labels or 
headers to present to a user when a user navigates to a cell. Therefore, 
I wish the entire algorithm was flipped and tells us what headers are a 
match for a given cell.

3. The one piece of information we do need when we are on a given <th> 
is whether to expose it with ROLE_ROWHEADER or ROLE_COLUMNHEADER in our 
GetRole() implementation. If scope isn't "row", "rowgroup", "col" or 
"colgroup" then we'll need to base that on the position in the table. It 
seems fairly obvious if the <th> is in an edge (but not corner) 
position, but other cases are less obvious.

I haven't gone through the algorithm in fine detail yet, mostly because 
of comment #2. We'd have to turn the algorithm inside out in order to 
evaluate it.

- Aaronj
Received on Wednesday, 29 October 2008 10:43:21 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:06 UTC