W3C home > Mailing lists > Public > www-style@w3.org > September 2006

table row order invariance vs. incremental layout efficiency (was Re: Specifying intrinsic width and table layout behavior)

From: L. David Baron <dbaron@dbaron.org>
Date: Wed, 13 Sep 2006 15:47:18 -0700
To: www-style@w3.org
Message-ID: <20060913224718.GA6278@ridley.dbaron.org>
On Tuesday 2006-08-29 18:09 -0700, L. David Baron wrote:
> http://dbaron.org/css/intrinsic/20060829

The table width calculation rules I described in this document are
invariant under changes in row order.  In other words, switching the
order of rows in a table (accounting for rearranging row-spanning cells
so they span the same rows) does not change the resulting width of the
table.  This invariant is maintained by most but not all current Web
browsers that I've tested.  (The exception I found is IE/Windows.)

What I've come to realize is that this invariant conflicts with being
able to do incremental rendering efficiently, since meeting it (within
the constraints of Web-compatibility) requires doing two passes over the
table, the first for non-column-spanning cells and the second for
column-spanning cells.  (These two passes are (1) the computation of the
intrinsic non-spanning widths and (2) the computation of the intrinsic
spanning widths of the columns.)  Maintaining the results of a two-pass
algorithm as content is incrementally appended to the table requires
redoing the second pass every time (or at least many times), since it
depends on the results of the first pass.

I wonder how useful people really think this invariant is, and whether
we should give it up in order to allow for a single-pass algorithm for
which we can implement more efficient incremental layout.


L. David Baron                                <URL: http://dbaron.org/ >
           Technical Lead, Layout & CSS, Mozilla Corporation

Received on Wednesday, 13 September 2006 22:47:23 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:26 UTC