mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 10:37:45 +00:00
LibWeb: Don't use the preferred increment as reference for distribution
The specification says we should distribute excess width proportionally to the width of the cell, not to the preferred increment. Doing the latter leads to distributing all excess width to just the cells which demand some increment, even if it's very modest. Moreover, there's code which partially implements the correct criteria just below the one we remove here.
This commit is contained in:
parent
13687085dd
commit
030b1a197b
5 changed files with 93 additions and 14 deletions
|
@ -14,23 +14,23 @@ Viewport <#document> at (0,0) content-size 800x600 children: not-inline
|
|||
Box <tr> at (10,10) content-size 72x19.46875 table-row children: not-inline
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <td> at (11,11) content-size 14.265625x17.46875 table-cell [BFC] children: inline
|
||||
BlockContainer <td> at (11,11) content-size 17.828571x17.46875 table-cell [BFC] children: inline
|
||||
line 0 width: 14.265625, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from TextNode start: 0, length: 1, rect: [11,11 14.265625x17.46875]
|
||||
"A"
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <td> at (29.265625,11) content-size 9.34375x17.46875 table-cell [BFC] children: inline
|
||||
BlockContainer <td> at (32.828571,11) content-size 11.828571x17.46875 table-cell [BFC] children: inline
|
||||
line 0 width: 9.34375, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from TextNode start: 0, length: 1, rect: [29.265625,11 9.34375x17.46875]
|
||||
frag 0 from TextNode start: 0, length: 1, rect: [32.828571,11 9.34375x17.46875]
|
||||
"B"
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <td> at (42.609375,11) content-size 42.390625x17.46875 table-cell [BFC] children: inline
|
||||
BlockContainer <td> at (48.657142,11) content-size 36.342857x17.46875 table-cell [BFC] children: inline
|
||||
line 0 width: 29.453125, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from TextNode start: 0, length: 3, rect: [42.609375,11 29.453125x17.46875]
|
||||
frag 0 from TextNode start: 0, length: 3, rect: [48.657142,11 29.453125x17.46875]
|
||||
"C D"
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
|
@ -0,0 +1,38 @@
|
|||
Viewport <#document> at (0,0) content-size 800x600 children: not-inline
|
||||
BlockContainer <html> at (0,0) content-size 800x600 [BFC] children: not-inline
|
||||
BlockContainer <body> at (8,8) content-size 784x21.46875 children: not-inline
|
||||
TableWrapper <(anonymous)> at (8,8) content-size 784x21.46875 [BFC] children: not-inline
|
||||
Box <table> at (8,8) content-size 784x21.46875 table-box [TFC] children: not-inline
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
Box <tbody> at (8,8) content-size 784x21.46875 table-row-group children: not-inline
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
Box <tr> at (8,8) content-size 784x21.46875 table-row children: not-inline
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <td> at (10,10) content-size 216.099903x17.46875 table-cell [BFC] children: inline
|
||||
line 0 width: 14.265625, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from TextNode start: 1, length: 1, rect: [10,10 14.265625x17.46875]
|
||||
"A"
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <td> at (230.099903,10) content-size 156.791546x17.46875 table-cell [BFC] children: inline
|
||||
line 0 width: 9.34375, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from TextNode start: 1, length: 1, rect: [230.099903,10 9.34375x17.46875]
|
||||
"B"
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <td> at (390.891450,10) content-size 399.108549x17.46875 table-cell [BFC] children: inline
|
||||
line 0 width: 29.453125, height: 17.46875, bottom: 17.46875, baseline: 13.53125
|
||||
frag 0 from TextNode start: 1, length: 3, rect: [390.891450,10 29.453125x17.46875]
|
||||
"C D"
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
||||
BlockContainer <(anonymous)> (not painted) children: inline
|
||||
TextNode <#text>
|
|
@ -0,0 +1,24 @@
|
|||
<style>
|
||||
td {
|
||||
border: 1px solid black;
|
||||
}
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
}
|
||||
</style>
|
||||
<table width="100%">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
A
|
||||
</td>
|
||||
<td>
|
||||
B
|
||||
</td>
|
||||
<td>
|
||||
C D
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
Loading…
Add table
Add a link
Reference in a new issue