Closed
Bug 350444
Opened 18 years ago
Closed 18 years ago
[FIX]Vertical borders in table containing col elements are not shown
Categories
(Core :: Layout: Tables, defect, P2)
Core
Layout: Tables
Tracking
()
VERIFIED
FIXED
mozilla1.9alpha1
People
(Reporter: daniel, Assigned: bzbarsky)
References
Details
(4 keywords)
Attachments
(6 files)
946 bytes,
text/html
|
Details | |
5.40 KB,
image/gif
|
Details | |
929 bytes,
application/xhtml+xml
|
Details | |
11.07 KB,
patch
|
Details | Diff | Splinter Review | |
6.54 KB,
patch
|
dveditz
:
approval1.8.0.9+
dveditz
:
approval1.8.1.1+
|
Details | Diff | Splinter Review |
6.54 KB,
patch
|
bernd_mozilla
:
review+
roc
:
superreview+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.0.6) Gecko/20060728 Firefox/1.5.0.6 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.0.6) Gecko/20060728 Firefox/1.5.0.6 I have a simple table. When defining col elements for each column, vertical borders within the table are not shown anymore. This must have been changed somewhere between Version 1.5 and 1.5.5, as it works in 1.5 but does not with the latest versions including 3.0a Reproducible: Always
Reporter | ||
Comment 1•18 years ago
|
||
Note: The bug seems to depend on the "rules" attribute. If not set, everything's fine. When removing the col elements, the borders are shown.
Reporter | ||
Comment 2•18 years ago
|
||
The Screenshot shows the rendering result of the testcase using Firefox 1.5.0. The vertical border in the first table is shown. (Which is, what I expect and Opera and IE shows too.)
Comment 3•18 years ago
|
||
Yes, using Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1b2) Gecko/20060827 BonEcho/2.0b2 also doesn't show any vertical borders inside the table. Please try different builds between 1.5.0.0 and 1.5.0.5 to minimize the regression range. That would make it easier to discover.
Reporter | ||
Comment 4•18 years ago
|
||
Works in Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.0.3) Gecko/20060426 Firefox/1.5.0.3 Does not work in any later release. So it seems to be broken between 1.5.0.3 and 1.5.0.4
Comment 5•18 years ago
|
||
Than one of these checkins should be responsible for that issue: http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=MOZILLA_1_8_0_BRANCH&branchtype=match&dir=&file=.*&filetype=regexp&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2006-04-30&maxdate=2006-06-02&cvsroot=%2Fcvsroot
Updated•18 years ago
|
Product: Firefox → Core
Updated•18 years ago
|
Component: General → Layout: Tables
Comment 6•18 years ago
|
||
I'm not seeing this with a current 1.8 branch SeaMonkey on the testcase, but I'm seeing this sometimes on bigger tables - not completely reproducable though, as sometimes it works in one browser window and doesn't in a different one. I have seen this for a long time though, AFAIK even before 1.8 branch was cut.
Component: Layout: Tables → General
Product: Core → Firefox
Updated•18 years ago
|
Product: Firefox → Core
QA Contact: general → general
Comment 7•18 years ago
|
||
I found this trunk regression range, but both ranges have nothing in common: http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=2006-02-10+21%3A00&maxdate=2006-02-11+06%3A00
Comment 8•18 years ago
|
||
I can reproduce this on a 2006-08-27 1.8.0.1 branch build. On the 1.8.1 branch, this regressed between 2006-02-26 and 2006-04-05, I don't have any builds inbetween. Could someone look for the precise regression range on 1.8.1 branch? Thanks.
Component: General → Layout: Tables
Flags: blocking1.8.1?
Flags: blocking1.8.0.8?
Keywords: testcase
QA Contact: general → layout.tables
Comment 9•18 years ago
|
||
Branch: http://tinderbox.mozilla.org/bonsai/cvsquery.cgi?treeid=default&module=AviarySuiteBranchTinderbox&branch=MOZILLA_1_8_BRANCH&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2006-03-15+02%3A00%3A00&maxdate=2006-03-16+04%3A00%3A00&cvsroot=%2Fcvsroot
Assignee | ||
Comment 10•18 years ago
|
||
I bet on trunk this regressed from bug 326105 and on branch it regressed from bug 322348. Certainly builds from before bug 326105 have a computed 1px left/right border on the <col> in that testcase, while builds since have a 0px border. The reason bug 322348 affected this is that for that bug we're ending up with the nsTableFrame as our style context parent instead of ending up with the colgroup, and the reason for that is that the style context it has doesn't have the nsCSSAnonBoxes::tableCol pseudo. Which makes sense, because it's not a pseudo column. So the net effect is the same as that of bug 326105 in terms of how the style context gets parented. But it seems that the mess that is rules painting somehow depends on inheriting from the colgroup or something? Bernd, do you have time to look at this? And could we _please_ add this to our regression tests, especially the pre-release ones? :( We really shouldn't be breaking stuff like this in security updates. :(
Assignee | ||
Updated•18 years ago
|
Flags: blocking1.9?
Comment 11•18 years ago
|
||
>Bernd, do you have time to look at this?
If you ask how can I refuse, but It will not be for 1.8.0.7
Assignee | ||
Comment 12•18 years ago
|
||
Yeah, this has been broken on the 1.8.0 branch long enough that fixing in 1.8.0.8 should be ok.
Comment 13•18 years ago
|
||
> And could we _please_ add this to our regression tests, especially the
> pre-release ones? :( We really shouldn't be breaking stuff like this in
> security updates. :(
Agreed - but add what specifically to the regression tests?
Comment 14•18 years ago
|
||
not going to block on this, will likely take a patch once a safe one has been created and well-tested.
Flags: blocking1.8.1? → blocking1.8.1-
Assignee | ||
Comment 15•18 years ago
|
||
> Agreed - but add what specifically to the regression tests?
The "simple testcase" from this bug.
Comment 16•18 years ago
|
||
>But it seems that the mess that is rules painting somehow depends on inheriting >from the colgroup or something? I am not sure what it is, but we have that hall of shame nomination for http://lxr.mozilla.org/seamonkey/source/layout/style/nsHTMLStyleSheet.cpp#167 This would require to get bug 43178 fixed.
Assignee | ||
Comment 17•18 years ago
|
||
I don't really think we want to do bug 43178 on the branch (though I do think we should do it on trunk)... I wonder whether we could safely break ReParentStyleContext on branch for just table cols...
Comment 18•18 years ago
|
||
> safely break ReParentStyleContext
Thats beyond my capabilities. I don't have a good style system understanding.
Assignee | ||
Comment 19•18 years ago
|
||
Well. I think it wouldn't be too hard to break it like that. The question is whether we could do it _safely_. That is, withour reintroducing the issues that bug 326105 and bug 322348 were trying to solve.
Comment 20•18 years ago
|
||
(In reply to comment #15) > > Agreed - but add what specifically to the regression tests? > > The "simple testcase" from this bug. > So that would catch this specific case - which is great - but I'm wondering if there was some other better way to catch this class of regressions.
Comment 21•18 years ago
|
||
how can we programmatically determine if this test case passes or fails? Is there something that can be detected by code running in content that will indicate pass/fail status? What about code running in chrome? If not, then please generate two pages that should be identical. If they are not identical, then the test should be marked as failing. One way to do this would be to put the first table in one file and the third table in another file, and change the text to be identical.
Blocks: test-suites
Assignee | ||
Comment 22•18 years ago
|
||
I really wish we actually had roc's "visual" regression tests. Then we could actually run the layout regression tests and compare results between point releases. If 1.8.0.6 differs from 1.8.0.5, we need to investigate, for example.
Comment 23•18 years ago
|
||
Getting the test framework in bug 344591 working would also be helpful here, wouldn't it?
Comment 24•18 years ago
|
||
(In reply to comment #23) > Getting the test framework in bug 344591 working would also be helpful here, > wouldn't it? > that's on my short list of things to do real soon, and the motivation for my "generate two pages" request. wanna help? But if this particular bug can be determined from dom-accessible data structures, so much the better.
Assignee | ||
Comment 25•18 years ago
|
||
> But if this particular bug can be determined from dom-accessible data
> structures,
Yeah, I think you can detect this with computed style....
Reporter | ||
Comment 26•18 years ago
|
||
With the given HTML the first and third table should be identical in width. While this is true on 1.5.0.3 it is not in newer versions. The missing border line causes a decrease of one pixel (if no explicit size is given by css or a html attribute). So a simple javascript could check that: onload = function() { var tables = document.getElementsByTagName("table"); alert(tables[0].offsetWidth == tables[2].offsetWidth); }; If I would have more details on what is necessary for the automated test I could add that function to the testcase. However this test would be pretty limited to only this bug and doesn't really check for the existence of a border but only for the correct width. So far I couldn't find a way to determine the border using getComputedStyle. Any hint is welcome.
Assignee | ||
Comment 27•18 years ago
|
||
Do getComputedStyle() on the <col> and look at the computed border-left-width and border-right-width?
Reporter | ||
Comment 28•18 years ago
|
||
No, always returns 0px even on the third example where the borders are visible. See http://www.birgin.de/test/bugzilla/col_bug.html
Reporter | ||
Comment 29•18 years ago
|
||
I really don't know which element holds the border-width value when using the "rules" attribute. Checking the border-width of all tr and td elements returns 0px for each table with a "rules" attribute set too.
Assignee | ||
Comment 30•18 years ago
|
||
> No, always returns 0px even on the third example where the borders are visible.
That example doesn't have any <col> elements.
I suggest trying your testcase in an old build that doesn't show this bug and seeing what the computed style for the <col>s in that first table is. For example, with a 2006-01-01 trunk build I see 1px computed styles in the first table in your testcase, as well as in the second one.
Reporter | ||
Comment 31•18 years ago
|
||
(In reply to comment #30) > That example doesn't have any <col> elements. Yes, but td elements. And the td element's border width is 0px as well. > I suggest trying your testcase in an old build that doesn't show this bug and > seeing what the computed style for the <col>s in that first table is. For > example, with a 2006-01-01 trunk build I see 1px computed styles in the first > table in your testcase, as well as in the second one. Yes. The same for the official 1.5.0.3 build Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.0.3) Gecko/20060426 Firefox/1.5.0.3 The next release (1.5.0.4) shows 0px for each value.
Assignee | ||
Comment 32•18 years ago
|
||
> Yes, but td elements. And the td element's border width is 0px as well. Yes. The borders are painted by the anonymous columns, not the table cells... Thats why we get this bug. > The next release (1.5.0.4) shows 0px for each value. Yep. That's this bug.
Reporter | ||
Comment 33•18 years ago
|
||
Does that mean the test should fail if the return value is 0px and should succeed if it is 1px? If so what is needed to create a usefull test file? Is it possible to use a HTML document and JavaScript? Just a function with a boolean return value?
Assignee | ||
Comment 34•18 years ago
|
||
> Does that mean the test should fail if the return value is 0px and should > succeed if it is 1px? With that testcase and for now, yes. If we ever fix bug 43178, that will change. > If so what is needed to create a usefull test file? davel?
Comment 35•18 years ago
|
||
(In reply to comment #34) > > If so what is needed to create a usefull test file? > > davel? "davel" does not scale as a creator of useful test files :-) Write a test case using jsunit (www.jsunit.net), and attach it to this bug. Here's an shell for such a test case: <!DOCTYPE html> <title>Testcase bug 350444</title> <script language="javascript" src="app/jsUnitCore.js"></script> <script> function testBug350444() { assertEquals(1,document.getElementById('td id').blah.blah.border-width) </script> <table> ... </table> You probably want to clean up the above shell so that it is a legal html doc, though :-)
Assignee | ||
Comment 36•18 years ago
|
||
> "davel" does not scale as a creator of useful test files :-)
I was just saying that "davel" might be able to answer the question, as he did. ;)
Comment 38•18 years ago
|
||
see comment 18, I will not do this for 1.8.0.9
Comment 39•18 years ago
|
||
Not a security exploit and the engineers are nervous about fixing this on a stability branch: removing from the blocker list.
Flags: blocking1.8.0.9? → blocking1.8.0.9-
Assignee | ||
Updated•18 years ago
|
Flags: in-testsuite?
Assignee | ||
Comment 40•18 years ago
|
||
Assignee | ||
Comment 41•18 years ago
|
||
The basic problem is that ProcessTableRulesAttribute ASS-umes things about style context parentage based on whether something is "a group" or not...
Assignee | ||
Comment 42•18 years ago
|
||
Assignee | ||
Comment 43•18 years ago
|
||
The only difference between branch and trunk patches is s/IsContentOfType/IsNodeOfType/, so I figure might as well get this some trunk bake time...
Attachment #244647 -
Flags: superreview?(roc)
Attachment #244647 -
Flags: review?(bernd_mozilla)
Assignee | ||
Comment 44•18 years ago
|
||
Renominating for branches. This is a nasty-ish regression from a crash fix we took on those branches, and the patch I just attached is quite safe...
Assignee: bernd_mozilla → bzbarsky
Blocks: 322348
Flags: blocking1.8.1?
Flags: blocking1.8.1-
Flags: blocking1.8.0.9?
Flags: blocking1.8.0.9-
OS: Windows XP → All
Priority: -- → P2
Hardware: PC → All
Summary: Vertical borders in table containing col elements are not shown → [FIX]Vertical borders in table containing col elements are not shown
Target Milestone: --- → mozilla1.9alpha
Comment 45•18 years ago
|
||
Comment on attachment 244647 [details] [diff] [review] Trunk version fixing just cols Man and I hoped soooo that the only time I will see this callbacks again will be when they are removed.
Attachment #244647 -
Flags: review?(bernd_mozilla) → review+
Assignee | ||
Comment 46•18 years ago
|
||
Yeah, I hear you. Let's just remove them on trunk, dammit!
Comment 47•18 years ago
|
||
this should be pretty safe for branch, the removal is big surgery but fantasai is on it.
Assignee | ||
Updated•18 years ago
|
Flags: blocking1.8.1? → blocking1.8.1.1?
Comment 48•18 years ago
|
||
Which patch do you want for branches? none of the "branch" versions appear to have reviews. Please ask for approval on the patch(es) you want to land.
Flags: blocking1.8.1.1?
Flags: blocking1.8.1.1+
Flags: blocking1.8.0.9?
Flags: blocking1.8.0.9+
Assignee | ||
Comment 49•18 years ago
|
||
I want the branch version of the trunk patch that has review requests. As comment 43 says, the two are identical except for a trivial name change on trunk. Once the trunk patch has been reviewed, I will request branch approval.
Attachment #244647 -
Flags: superreview?(roc) → superreview+
Assignee | ||
Comment 50•18 years ago
|
||
Fixed on trunk.
Status: NEW → RESOLVED
Closed: 18 years ago
Flags: blocking1.9?
Resolution: --- → FIXED
Assignee | ||
Comment 51•18 years ago
|
||
Comment on attachment 244646 [details] [diff] [review] Branch version only fixing cols (so just the regression) This is a pretty safe fix for a rendering regression one of our security fixes introduced...
Attachment #244646 -
Flags: approval1.8.1.1?
Attachment #244646 -
Flags: approval1.8.0.9?
Reporter | ||
Comment 52•18 years ago
|
||
Good work! Thanks for the quick response and all the efforts.
Comment 53•18 years ago
|
||
Comment on attachment 244646 [details] [diff] [review] Branch version only fixing cols (so just the regression) approved for 1.8/1.8.0 branches, a=dveditz for drivers
Attachment #244646 -
Flags: approval1.8.1.1?
Attachment #244646 -
Flags: approval1.8.1.1+
Attachment #244646 -
Flags: approval1.8.0.9?
Attachment #244646 -
Flags: approval1.8.0.9+
Assignee | ||
Comment 54•18 years ago
|
||
Fixed for 1.8.0.9 and 1.8.1.1.
Keywords: fixed1.8.0.9,
fixed1.8.1.1
Updated•18 years ago
|
Keywords: fixed1.8.1.1 → verified1.8.1.1
Comment 55•18 years ago
|
||
Vertical border are shown in each latest nightly build. Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.9pre) Gecko/20061115 Firefox/1.5.0.9pre Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1) Gecko/20061115 BonEcho/2.0 Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20061115 Minefield/3.0a1 But one bug sliped through. We only talked about vertical borders. While checking if the fix is working I noticed that also horizontal borders aren't visible. Dunno why I havn't seen that before. While attachment 235720 [details] is working fine attachment 244643 [details] shows the issue. I'll file a new bug for this later.
Status: RESOLVED → VERIFIED
Keywords: fixed1.8.0.9 → verified1.8.0.9
Comment 56•18 years ago
|
||
(In reply to comment #55) > While attachment 235720 [details] [edit] is working fine attachment 244643 [details] [edit] shows the issue. I'll > file a new bug for this later. This issue occurs only for XHTML documents. If you save attachment 244643 [details] and rename it to test.html all is working fine. Anyone know if there is already a bug which covers this issue?
Assignee | ||
Comment 57•18 years ago
|
||
> But one bug sliped through.
It didn't slip through. It's just never worked, unlike vertical borders. If you notice, the first patch I posted in this bug fixed both, but I decided to fix the regression and only the regression on branch, especially since the rows problem only appears in XHTML. On trunk, all this code is going away by 1.9 anyway, with any luck.
You need to log in
before you can comment on or make changes to this bug.
Description
•