VERIFIED FIXED 5820
Table cells with width:auto should use width from their <col>
https://bugs.webkit.org/show_bug.cgi?id=5820
Summary Table cells with width:auto should use width from their <col>
mitz
Reported 2005-11-24 11:00:17 PST
A table cell whose width is 'auto' should use the width property of the corresponding col element if there is one. WinIE renders the testcase as expected.
Attachments
testcase (1.19 KB, text/html)
2005-11-24 11:01 PST, mitz
no flags
Use <col> width during layout when necessary (4.91 KB, patch)
2005-11-24 11:26 PST, mitz
darin: review+
mitz
Comment 1 2005-11-24 11:01:30 PST
Created attachment 4790 [details] testcase
mitz
Comment 2 2005-11-24 11:26:02 PST
Created attachment 4791 [details] Use <col> width during layout when necessary I am not sure that this is the right approach (rather than doing some crazy CSS "inheritance"). Also, for table cells with colspan > 1, it falls back on "auto", which didn't seem worse than any other option I tried or what I saw in Firefox.
Darin Adler
Comment 3 2005-11-25 13:54:42 PST
Comment on attachment 4791 [details] Use <col> width during layout when necessary This looks just right to me. r=me If it was me, I would have used a return rather than "w=" in RenderTableCell::styleOrColWidth, but there are arguments that go both ways on this very minor coding style issue. It would be slightly better if RenderTableCell::calcMinMaxWidth() was written so that it did not call styleOrColWidth() unless nowrap is set, but worrying about this smacks of premature optimization.
Note You need to log in before you can comment on or make changes to this bug.