Remarks on Tables draft

Terry Allen (
Tue, 25 Jul 95 11:50:20 EDT

Some comments and questions on:

| HTML Tables 7th July 1995
| INTERNET DRAFT Dave Raggett, W3C
| <draft-ietf-html-tables-00.txt>
| Tables can contain a wide range of content, such as headers, lists,
| paragraphs, forms, figures, preformatted text and even nested
| tables. When the table is flush left or right, subsequent elements
| will be flowed around the table if there is sufficient room. This
| behaviour is disabled when the noflow attribute is given or the
| table align attribute is center (the default), or justify.

Does this mean one cannot have a centered table with text flowing
around both sides?

| There are several points to note:

Not points to note, but rendering requirements.

| * By default, header cells are centered while data cells are flush
| left. This can be overriden by the ALIGN attribute for the cell
| or a matching HSPEC element.

Why not use the same default?

| * The user agent should be able to recover from a missing <TR> tag
| prior to the first row as the TH and TD elements can only occur
| within the TR element.

Why not then make the minimization o - instead of - o ?

| * It is invalid to have cells overlap, see below for an example.
| In such cases, the rendering is implementation dependent.

It would be good to point out that markup that is valid according
to the DTD may produce unpredictable results, rather than just calling
it invalid.


FEW seems to be a typo, as it does not appear in %border.styles;.
Please, everybody, test your examples with a validating parser
before you post!

| Note: the end tags for THEAD, TBODY and TFOOT can always be omitted,
| but if you have a THEAD, then you will need to include a TBODY start
| tag too. Otherwise, the parser won't be able to distinguish body
| rows from head rows.

A good reason to require an end tag on THEAD, isn't it?

| This can be one of: LEFT, CENTER, RIGHT, JUSTIFY and CHAR. User
| agents may treat Justify as left alignment if they lack support
| for text justification. ALIGN=CHAR is used for aligning cell
| contents on a particular character. The attribute value for
| ALIGN is case insensitive.

A question that came up wrt CALS, and which I repeat here: how does
one set the gutter width between columns? (I don't have the answer
for CALS, can't see how to do it.) This was desired recently at ORA.

| This is used with align=char to specify the relative offset of
| the alignment character with respect to the width of the cell.
| The attribute value takes the form of a positive integer in the
| range 1 to 100 followed by a percent sign, e.g. charoff="50%".

Obviously the % is unneeded; one could make CHAROFF take NUMBER or
NUTOKEN rather than CDATA.

| <!ELEMENT table - - (caption?, (colw|hspec|vspec)*, thead?, tbody, tfoot?)>
| <!ELEMENT caption - O (%text)+>
| <!ELEMENT colw - O EMPTY>
| <!ELEMENT hspec - O EMPTY>
| <!ELEMENT vspec - O EMPTY>
| <!ELEMENT thead - O tr+>
| <!ELEMENT tbody O O tr+>
| <!ELEMENT tfoot - O tr+>
| <!ELEMENT tr - O (th|td)+>
| <!ELEMENT (th|td) - O %body.content>

We may be stuck with TH and TD, but I just want to point out the rich
possibilities for tag abuse. If I can put a table inside a table,
if I can distinguish THEAD and TFOOT from TBODY, if I can set up
rendering properties based on the number column, or the number and
class of row, I could probably set up proper table headings, footings,
and even table stubs without having two cell elements. As two
elements are provided, they'll be abused for presentation rather than
used with their apparently intended semantics. Be prepared, and too
bad for the print impaired!

| <!ATTLIST table
| width CDATA #IMPLIED -- table width relative to window --
| cols NUMBER #IMPLIED -- used for immediate display mode --
| border (%border.styles) #IMPLIED -- see above definition --
| nowrap (nowrap) #IMPLIED -- disable word wrap inside table --
| >

Why is it useful to apply nowrap at the table level? shouldn't it be
available at the column level?

| axis CDATA #IMPLIED -- defaults to cell content --
| axes CDATA #IMPLIED -- list of axis names --

Axis and Axes appear not to be documented.


Terry Allen  (   O'Reilly & Associates, Inc.
Editor, Digital Media Group    101 Morris St.
			       Sebastopol, Calif., 95472

A Davenport Group sponsor. For information on the Davenport Group see or