RESOLVED FIXED 11188
Setting hspace on a table overrides align=center
https://bugs.webkit.org/show_bug.cgi?id=11188
Summary Setting hspace on a table overrides align=center
mitz
Reported 2006-10-06 02:06:31 PDT
A table with align=center is not centered if it also specifies hspace. See attached test case.
Attachments
Test case (134 bytes, text/html)
2006-10-06 02:07 PDT, mitz
no flags
Patch that moves align=center into code instead of CSS (1.39 KB, patch)
2008-01-10 11:57 PST, Dave Hyatt
mitz: review+
mitz
Comment 1 2006-10-06 02:07:23 PDT
Created attachment 10945 [details] Test case
Eric Seidel (no email)
Comment 2 2008-01-10 11:23:35 PST
An example of this on a real website: http://www.iloveindia.com/astrology/index.html
Dave Hyatt
Comment 3 2008-01-10 11:46:58 PST
Interesting. Firefox appears to be somehow giving some mapped attributes a higher precedence than others. In particular, it makes sure hspace gets mapped in before align does.
Dave Hyatt
Comment 4 2008-01-10 11:56:06 PST
The bug is that we implemented align=center in the CSS file. This created a situation where hspace would always win (instead of allowing attribute order to determine the winner).
Dave Hyatt
Comment 5 2008-01-10 11:57:41 PST
Created attachment 18368 [details] Patch that moves align=center into code instead of CSS This patch will also improve the style sharing performance of tables, since the attribute selector rule in html4.css prevented tables from sharing style with one another.
mitz
Comment 6 2008-01-10 12:03:40 PST
Comment on attachment 18368 [details] Patch that moves align=center into code instead of CSS r=me. Add a test case if not covered by an existing one.
Dave Hyatt
Comment 7 2008-01-11 10:27:53 PST
Fixed in r29409.
Note You need to log in before you can comment on or make changes to this bug.