First row with no cells breaks painting of collapsed borders for the whole table

RESOLVED FIXED in mozilla5

Status

()

Core
Layout: Tables
P1
normal
RESOLVED FIXED
7 years ago
7 years ago

People

(Reporter: colin.m.pickup, Assigned: bz)

Tracking

unspecified
mozilla5
x86
Windows Vista
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(2 attachments)

(Reporter)

Description

7 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.151 Safari/534.16
Build Identifier: 4.0

Rather than collapsing borders such that they overlap, the borders disappear completely. After trial and error enabling and disabling other CSS rules, I found that the borders appeared again when I removed a rule that applies display: none to the th cells of the table. This problem doesn't happen if it is a td that is hidden, only a th elemnt, as far as I can tell (see the demonstration above;

Reproducible: Always

Steps to Reproduce:
1. Create a valid table with table, thead, tr, th, tbody, and td elemnts
2. Apply border-collapse:collapse to the table
3. Apply display: none to a th element in the table
Actual Results:  
All borders disappear from all elements of the table, including around the table itself

Expected Results:  
The borders collapse as usual and the th elements are hidden
Summary: border-collapse: collapse hides all borders when th cells are display: none → Firs row with no cells breaks painting of collapsed borders for the whole table
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: Firs row with no cells breaks painting of collapsed borders for the whole table → First row with no cells breaks painting of collapsed borders for the whole table
Created attachment 521626 [details] [diff] [review]
fix

Colin, thanks for reporting this!

roc, the idea here is that we don't want to decide we're at the end just because the first row that intersects the bc damage area has no cells in it.  I considered writing this more like Next() also, but I _think_ all the sane cases would end up with a dead cell here, so this should be ok and we don't need to iterate the rows in the group.  I think.
Attachment #521626 - Flags: review?(roc)
Component: DOM: CSS Object Model → Layout: Tables
Priority: -- → P1
QA Contact: style-system → layout.tables
Whiteboard: [need review]
Whiteboard: [need review] → [need landing]
Assignee: nobody → bzbarsky
Pushed http://hg.mozilla.org/mozilla-central/rev/d9e063c5402d
Status: NEW → RESOLVED
Last Resolved: 7 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Whiteboard: [need landing]
Target Milestone: --- → mozilla2.2
You need to log in before you can comment on or make changes to this bug.