- From: L. David Baron <dbaron@dbaron.org>
- Date: Tue, 11 Jul 2006 15:11:06 -0700
- To: www-style@w3.org
- Message-ID: <20060711221106.GA7435@ridley.dbaron.org>
I think the CSS 2.1 spec should be clarified so that it is clearer that (in the general case) the 'empty-cells' property has no effect on layout. This property is defined here: http://www.w3.org/TR/2006/WD-CSS21-20060411/tables.html#propdef-empty-cells By the general case, I mean all cases except for the case mentioned in the special-case rule (which I will address in another message, shortly): # Furthermore, if all the cells in a row have a value of 'hide' and have # no visible content, then the row has zero height and there is vertical # border-spacing on only one side of the row. So, in other words, I'm proposing that the paragraph which currently begins: # A value of 'hide' means that no borders or backgrounds are drawn # around/behind empty cells (see point 6 in 17.5.1). be split into two paragraphs immediately after the quoted text and a Note inserted into the break, with the text: # Note: When the 'empty-cells' property causes borders to be hidden, # elements are still positioned as though the borders were present. This note simply reflects what is already required by the statement in http://www.w3.org/TR/2006/WD-CSS21-20060411/box.html#border-properties : # The border properties specify the width, color, and style of the # border area of a box. These properties apply to all elements. which is not overridden by anything else in the spec for empty cells (except for the special case mentioned above). The definition of 'empty-cells: hide' currently says that the borders are not drawn, but does not specify that the border area of the cells is reduced, and the definition of the separated borders model refers to the distances between the borders of cells (that is, the distances between the border edges of the cells, which includes the border area). I've written some tests to check that this clarification is compatible with existing implementations: http://lists.w3.org/Archives/Public/www-archive/2006Jul/att-0007/empty-cells-2-standards.html http://lists.w3.org/Archives/Public/www-archive/2006Jul/att-0007/empty-cells-2-quirks.html In particular, the first two examples in each of those pages (for standards mode and quirks mode) are relevant for this message. This clarification would make the spec clearer that the middle column in the first example should be much wider than needed by the borders and the width of the "X", and that the middle row in the second example should be much taller than needed by the borders and the height of the "X". The following table uses "1" to indicate compatibility with the behavior that I propose to clarify and "0" to indicate that the column/row is instead collapsed around the size of the borders plus the "X". 1 2 1 2 Test number (1 == column width; 2 == row height) S S Q Q Mode (S == standards mode; Q == quirks mode) ========================================================= 1 0 1 1 Internet Explorer 6.0.2900.2180 0 0 0 0 Firefox 1.5.0.4 (Linux) [Mozilla 1.8.0.4] 1 1 1 1 Opera 9.00 (Linux) 1 1 1 1 Safari 1.3.2 (v. 312.6) 1 1 1 1 Konqueror 3.5.3-0.4fc5 I'm quite happy to change Mozilla's behavior to match most other browsers here. (In fact, I've already made the change on a development branch.) (Internet Explorer's behavior in standards mode seems to me to be an over-implementation of the exception I mentioned above.) -David -- L. David Baron <URL: http://dbaron.org/ > Technical Lead, Layout & CSS, Mozilla Corporation
Received on Tuesday, 11 July 2006 22:11:24 UTC