Last Comment Bug 458033 - Large rowspans stretch tables vertically
: Large rowspans stretch tables vertically
: testcase
Product: Core
Classification: Components
Component: Layout: Tables (show other bugs)
: Trunk
: x86 Linux
-- normal (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
Depends on:
  Show dependency treegraph
Reported: 2008-10-01 06:34 PDT by Matthew Wakeling
Modified: 2008-10-02 23:27 PDT (History)
0 users
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

testcase from url (24.95 KB, text/html)
2008-10-02 23:23 PDT, Bernd
no flags Details

Description User image Matthew Wakeling 2008-10-01 06:34:58 PDT
User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/2008071420 Iceweasel/3.0.1 (Debian-3.0.1-1)
Build Identifier: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/2008071420 Iceweasel/3.0.1 (Debian-3.0.1-1)

When rendering a table with style border-collapse: separate, cells seem to have a minimum height of the content plus some small amount per rowspan. This becomes a problem when trying to make two columns have slightly differing numbers of rows by using lowest common multiple rowspans, as shown in the first table in the example web page.

I know this is an obscure problem, but it may exhibit itself in undesirable behaviour in other situations. If you set border-collapse to collapse, then the problem goes away.

Reproducible: Always

Steps to Reproduce:
1. Create a table, and set the style border-collapse to separate (the default).
2. Have a row that has a large rowspan, and no other cells forcing the size of the row.
Actual Results:  
The table is very large vertically.

Expected Results:  
The table should be no larger than if the rowspan was one.
Comment 1 User image Matthew Wakeling 2008-10-01 06:37:56 PDT
It seems that the amount of vertical space added to the rows is non-linear. Three data points are:

Rowspan = 1, row height = 21 pixels
Rowspan = 20, row height = 36 pixels
Rowspan = 50, row height = 96 pixels
Comment 2 User image Bernd 2008-10-02 23:23:11 PDT
Created attachment 341589 [details]
testcase from url
Comment 3 User image Bernd 2008-10-02 23:27:35 PDT
this depends both on the cellspacing and the cellpadding. Both of them default to 1px. Setting them explicitly makes the problem more obvious.

Note You need to log in before you can comment on or make changes to this bug.