Skip to content

Commit 74beb3a

Browse files
committed
--HG-- extra : convert_revision : svn%3A73dc7c4b-06e6-40f3-b4f7-9ed1dbc14bfc/trunk%402097
1 parent a18ba9a commit 74beb3a

2 files changed

Lines changed: 182 additions & 94 deletions

File tree

css2/tables.src

Lines changed: 29 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
22
<html lang="en">
3-
<!-- $Id: tables.src,v 2.63 2003-04-14 15:26:56 bbos Exp $ -->
3+
<!-- $Id: tables.src,v 2.64 2003-06-07 01:02:16 bbos Exp $ -->
44
<head>
55
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1">
66
<title>Tables</title>
@@ -28,13 +28,6 @@ border models in CSS&nbsp;2.1). Authors may align data vertically or
2828
horizontally within a cell and align data in all cells of a row or
2929
column.
3030

31-
<P>Authors may also specify the aural rendering of a table; how
32-
headers and data will be spoken. In the document language, authors may
33-
label cells and groups of cells so that when rendered aurally, cell
34-
headers are spoken before cell data. In effect, this "serializes" the
35-
table: users browsing the table aurally hear a sequence of headers
36-
followed by data.
37-
3831
<div class="example"><P>
3932
Here is a simple three-row, three-column
4033
table described in HTML 4.0:
@@ -57,15 +50,16 @@ and six data cells (the TD elements). Note that the three columns
5750
of this example are specified implicitly: there are as many
5851
columns in the table as required by header and data cells.
5952

60-
<P>The following CSS rule centers the text horizontally
61-
in the header cells and present the data with a bold font weight:</P>
53+
<P>The following CSS rule centers the text horizontally in the header
54+
cells and presents the text in the header cells with a bold font
55+
weight
6256

6357
<PRE>
6458
th { text-align: center; font-weight: bold }
6559
</PRE>
6660

6761
<P>The next rules align the text of the header cells on their baseline
68-
and vertically centers the text in each data cell:</p>
62+
and vertically center the text in each data cell:</p>
6963

7064
<PRE>
7165
th { vertical-align: baseline }
@@ -94,21 +88,6 @@ the border between row1 and row2 be? We discuss this in the section on
9488
caption { caption-side: top }
9589
</PRE>
9690

97-
<P><del>Finally, the following rule specifies that, when rendered aurally,
98-
each row of data is to be spoken as a "Header, Data, Data":</del></P>
99-
100-
<PRE>
101-
<del>th { speak-header: once }</del>
102-
</PRE>
103-
104-
<P><del>For instance, the first row would be spoken "Header1 Cell1 Cell2".
105-
On the other hand, with the following rule:</del></p>
106-
107-
<PRE>
108-
<del>th { speak-header: always }</del>
109-
</PRE>
110-
111-
<P><del>it would be spoken "Header1 Cell1 Header1 Cell2". </del>
11291
</div>
11392

11493
<P>The preceding example shows how CSS works with HTML 4.0 elements;
@@ -201,7 +180,8 @@ name="value-def-table-header-group">table-header-group</a></span></strong>
201180
(In HTML: THEAD) <dd>Like 'table-row-group', but for visual formatting,
202181
the row group is always displayed before all other rows and rowgroups
203182
and after any top captions. Print user agents may repeat
204-
header rows on each page spanned by a table.
183+
header rows on each page spanned by a table. Use of multiple elements
184+
with 'display: table-header-group' is undefined.
205185

206186
<dt><strong><span class="index-def" title="table-footer-group"><a
207187
class="value-def"
@@ -211,7 +191,8 @@ name="value-def-table-footer-group">table-footer-group</a></span></strong>
211191
<dd>Like 'table-row-group', but for visual formatting, the row group is
212192
always displayed after all other rows and rowgroups and before any
213193
bottom captions. Print user agents may repeat footer rows on each page
214-
spanned by a table.
194+
spanned by a table. Use of multiple elements with 'display:
195+
table-footer-group' is undefined.
215196

216197
<dt><strong><span class="index-def" title="table-column"><a
217198
class="value-def"
@@ -300,23 +281,30 @@ object corresponding to a 'table' element will be
300281
generated between P and T. This object will span all consecutive siblings
301282
(in the document tree) of T that require a 'table' parent:
302283
'table-row', 'table-row-group', 'table-header-group',
303-
'table-footer-group', 'table-column', 'table-column-group', and 'table-caption'.
284+
'table-footer-group', 'table-column', 'table-column-group', and
285+
'table-caption'.
286+
T and T's siblings may also be anonymous 'table-row' objects generated
287+
by rule&nbsp;1.
304288

305289
<li>If the parent P of a 'table-column' element T is not a 'table',
306290
'inline-table', or 'table-column-group' element, an
307291
object corresponding to a 'table' element will be
308292
generated between P and T. This object will span all consecutive siblings
309293
(in the document tree) of T that require a 'table' parent:
310294
'table-row', 'table-row-group', 'table-header-group',
311-
'table-footer-group', 'table-column', 'table-column-group', and 'table-caption'.
295+
'table-footer-group', 'table-column', 'table-column-group', and
296+
'table-caption', including any anonymous 'table-row' objects generated
297+
by rule&nbsp;1.
312298

313299
<li>If the parent P of a 'table-row-group' (or 'table-header-group',
314-
'table-footer-group', or 'table-column-group') element T is not a 'table' or 'inline-table', an
300+
'table-footer-group', or 'table-column-group' or 'table-caption')
301+
element T is not a 'table' or 'inline-table', an
315302
object corresponding to a 'table' element will be generated between P
316303
and T. This object will span all consecutive siblings (in the document
317304
tree) of T that require a 'table' parent: 'table-row',
318305
'table-row-group', 'table-header-group', 'table-footer-group',
319-
'table-column', 'table-column-group', and 'table-caption'.
306+
'table-column', 'table-column-group', and 'table-caption', including
307+
any anonymous 'table-row' objects generated by rule&nbsp;1.
320308

321309
<li>If a child T of a 'table' element (or 'inline-table') P is not a
322310
'table-row-group', 'table-header-group', 'table-footer-group', or
@@ -446,9 +434,9 @@ col.totals { width: 5em }
446434

447435
<P>In terms of the <a href="visuren.html">visual formatting model</a>,
448436
a table may behave like a <a
449-
href="visuren.html#block-level">block-level</a> or replaced <a
437+
href="visuren.html#block-level">block-level</a> or <a
450438
href="visuren.html#inline-level">inline-level</a> element. Tables have
451-
content, padding, borders, and margins.
439+
content, <del>padding,</del> borders, and margins.
452440

453441
<P>In both cases, the table element generates an <a
454442
href="visuren.html#anonymous">anonymous</a> box that contains the
@@ -596,7 +584,7 @@ it, e.g., as in the figure on the left.
596584
<div class="figure">
597585
<p><img src="images/table-overlap.png" alt="One table with overlapping
598586
cells and one without"> <p class="caption">On the left, one possible
599-
rendering of an erroneous HTML 4.0 table; on the right, the only
587+
rendering of an erroneous HTML 4 table; on the right, the only
600588
possible formatting of a similar, non-HTML table.
601589
</div>
602590
</div>
@@ -666,8 +654,8 @@ centered. (And thus, in this model, the rows together exactly cover
666654
the table, leaving no gaps; ditto for the columns.) In the <a
667655
href="#separated-borders">separated borders model,</a> the edges
668656
coincide with the <a href="box.html#border-edge">border edges</a> of
669-
cells. (And thus, in this model, there may be gaps between the rows
670-
and columns, corresponding to the <span
657+
cells. (And thus, in this model, there may be gaps between the rows,
658+
columns, row groups or column groups, corresponding to the <span
671659
class="propinst-border-spacing">'border-spacing'</span> property.)
672660

673661
<div class="html-example">
@@ -680,13 +668,14 @@ row. The following HTML code and style rules</p>
680668
&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"&gt;
681669
&lt;HTML&gt;
682670
&lt;HEAD&gt;
671+
&lt;TITLE&gt;Table example&lt;/TITLE&gt;
683672
&lt;STYLE type="text/css"&gt;
684-
TABLE { background: #ff0; border-collapse: collapse }
673+
TABLE { background: #ff0; border-collapse: collapse;
674+
empty-cells: hide }
685675
TD { background: red; border: double black }
686676
&lt;/STYLE&gt;
687677
&lt;/HEAD&gt;
688678
&lt;BODY&gt;
689-
&lt;P&gt;
690679
&lt;TABLE&gt;
691680
&lt;TR&gt;
692681
&lt;TD&gt; 1
@@ -842,7 +831,7 @@ is greater than MCW, W is the minimum cell width. A value
842831
of 'auto' means that MCW is the minimum cell width.
843832

844833
<P>Also, calculate the "maximum" cell width of each cell: formatting
845-
then content without breaking lines other than where explicit line
834+
the content without breaking lines other than where explicit line
846835
breaks occur.
847836

848837
<li>For each column, determine a maximum and minimum column width from

0 commit comments

Comments
 (0)