User-Agent: Mozilla/5.0 (X11; U; SunOS sun4u; fr-FR; rv:1.7.5) Gecko/20041221
Build Identifier: Mozilla/5.0 (X11; U; SunOS sun4u; fr-FR; rv:1.7.5) Gecko/20041221
I have a table of 3 rows of 6 cells. The second row is painted red by applying
"background-color: red;" to the TR.
If I apply "display: inherit;" to the TR, all red cells are moved under the
first cell of the first row.
Steps to Reproduce:
Load file "bug.html"
All red cells are moved under the first cell of the first row.
I would expect a "normal" table like file "normal.html".
Internet Explorer displays "bug.html" like "normal.html".
Opera displays all red cells under the first cell of the first row AND does the
same for the third row.
Created attachment 180785 [details]
Test case showing the bug
Created attachment 180786 [details]
This is not because of 'display:inherit'. This is because you are applying
'display:table-row-group' to the TR element (albeit indirectly).
Not sure what the result should be though; Opera does something different.
Mozilla's rendering is correct. See
http://www.w3.org/TR/CSS21/tables.html#anonymous-boxes for the reason.
Note that IE doesn't really allow display changes on HTML table-related
elements, other than to "none". So IE is just ignoring your CSS altogether.
as Boris said, dont compare to IE if display types are involved
Please note that IE is correct per CSS 2.1 as browsers may ignore 'display' on
HTML table elements. (<http://www.w3.org/TR/CSS21/tables.html#q2>)
Thank you for the explanation.
In fact, what I wanted to do is the following.
I want do display or not some rows in the table, depending in the style sheet used.
In the "display all rows" style sheet, I had put
and in the "display only relevant rows" style sheet, I had put
So the question is: what should I put instead of "display: inherit;" ?