iMyth / flying-saucer

Automatically exported from code.google.com/p/flying-saucer
1 stars 0 forks source link

Table row height incorrect with fix height #47

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
*** This issue was imported from http://java.net/jira/browse/XHTMLRENDERER-331

It was reported by jamjim on 27.09.2010 19:42:09 +0200 and last updated in the 
previous bug tracker on 01.12.2010 18:36:44 +0100

Found in
Operating System: All
Platform: All

The priority for this issue at migration was Major.

Original description: 
When a table has a height, only the last row is stretched to fill the space.  

CSS2.1 spec is pretty clear that behaviour is not defined:

"CSS 2.1 does not define how extra space is distributed when the 'height'
property causes the table to be taller than it otherwise would be"

Not very useful!   However, all browsers I've tried stretch all the rows that
have no specified height.  Firefox, IE, opera look like they give proportional
extra space.   Chrome and Safari look more like they are giving equal extra 
space.

<table style="height:300px;width:100px;">
  <tr style="background-color:red">
    <td><div style="height:20px"/></td>
  </tr>
  <tr style="background-color:blue">
     <td><div style="height:40px"/></td>
  </tr>
  <tr style="height:20px; background-color:green">
     <td><div style="height:5px"/></td>
  </tr>
</table>

Original issue reported on code.google.com by pdoubl...@gmail.com on 16 Feb 2011 at 9:47

GoogleCodeExporter commented 9 years ago
jamjim wrote on 01.12.2010 18:36:44 +0100:
If I understand correctly, the available remaining space cannot be determined
until all rows have been layed out.  By then, it's too late to easily change the
heights of the rows.   Am I right in thinking this isn't easy to fix?

Original comment by pdoubl...@gmail.com on 16 Feb 2011 at 9:47