Closed Bug 717854 Opened 12 years ago Closed 12 years ago

Using <col> and <colgroup>, border of table-column-group incorrectly drawn on every table-column

Categories

(Core :: CSS Parsing and Computation, defect)

9 Branch
x86_64
Windows 7
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: rasamassen, Unassigned)

Details

Attachments

(1 file)

Attached file colgroup.html
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.7 (KHTML, like Gecko) Chrome/16.0.912.75 Safari/535.7

Steps to reproduce:

Specified a border around a <col> with a span > 1.


Actual results:

Border was applied to each column within the <col> individually rather than to the entire table-column-group


Expected results:

Border is applied to the entire table-column-group rather than each individual table-column, just as borders applied to table-row-groups (<thead>, <tbody>, <tfoot>) are applied to the entire table-row-group rather than the individual table-rows.

The attached file demonstrates this bug, including revealing the inconsistency with how table-column-groups are treated as compared to table-row-groups. The attached file fails in FF8, but succeeds in Chrome 16.
Attachment #588310 - Attachment mime type: text/plain → text/html
The table-column-group is the <colgroup>.  It works just like table-row-groups do.

The <col> is a table-column in CSS terms.  See http://www.whatwg.org/specs/web-apps/current-work/multipage/rendering.html#tables

What should happen for span > 1 on a <col> is an interesting question.  CSS has no provisions for table-column elements spanning multiple columns, and HTML5 doesn't define how to map span > 1 into CSS in a useful way.  The way Gecko does this mapping is by creating a new table-column box for each column spanned by the <col>.  I don't see another way to represent <col span> within the CSS table model.  It sounds like Chrome is just violating the CSS table model instead.

What you should probably do is raise this as an issue on the HTML5 spec: it needs to define processing for visual UAs for <col> with span > 1.
Oh, I was wrong.  HTML5 does define this.  http://www.whatwg.org/specs/web-apps/current-work/multipage/rendering.html#tables says:

  For the purposes of the CSS table model, the col element is expected to be treated as if
  it was present as many times as its span attribute specifies.

which is exactly what we do.

Please do file a bug on WebKit to follow the spec here?
Status: UNCONFIRMED → RESOLVED
Closed: 12 years ago
Resolution: --- → INVALID
Actually, I just went ahead and filed https://bugs.webkit.org/show_bug.cgi?id=76246
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: