W3C home > Mailing lists > Public > www-style@w3.org > July 2012

Re: [CSS21] border-collapse with rowspan or colspan

From: Gérard Talbot <www-style@gtalbot.org>
Date: Tue, 10 Jul 2012 11:09:09 -0400
Message-ID: <9a1b43566c1c2b46f3fe2b476e5db9b0.squirrel@ed-sh-cp3.entirelydigital.com>
To: "Simon Sapin" <simon.sapin@kozea.fr>
Cc: "WWW Style" <www-style@w3.org>

Le Mar 10 juillet 2012 6:53, Simon Sapin a écrit :
> Hi,
>
> The collapsing border model for tables is not well-defined and not
> interoperable in presence of cells with colspan or rowspan > 1.
>
> Test case:
>
> http://dabblet.com/gist/3082417
>
>      <style>td { padding: 10px }</style>
>      <table style="border-collapse: collapse; margin: 50px">
>        <tr style="border: 1px solid blue">
>          <td rowspan=2>A</td>
>          <td>B</td>
>        </tr>
>        <tr style="border: 20px solid red">
>          <td>C</td>
>          <td>D</td>
>        </tr>
>      </table>

There seems to be a problem with that test. How many columns does (or
should) that table have? It seems there is 3 columns (from looking at 2nd
row) but the first row uses only 2 columns.

>
> WebKit, Gecko and Opera give three different renderings,

If the table is wrongly/imbalancely designed, then different renderings is
to be expected.

> none obviously
> better (to me) than the others. The only consistent detail is that cells
> (with rowspan or colspan) never have borders inside.
>
> However, the problematic cases are not very interesting so I suggest
> leaving this undefined until someone wants to make css3-tables in a few
> decades. Maybe add a note in CSS 2.1 saying explicitly that this is
> undefined.
>
> In the meantime, I’ll do whatever is more convenient in WeasyPrint.

Gérard

-- 
CSS 2.1 Test suite RC6, March 23rd 2011
http://test.csswg.org/suites/css2.1/20110323/html4/toc.html

Contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/

Web authors' contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/web-authors-contributions-css21-testsuite.html
Received on Tuesday, 10 July 2012 15:09:39 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:56 GMT