Missing spanning rows in print preview at page break.

RESOLVED FIXED in mozilla11

Status

()

Core
Printing: Output
RESOLVED FIXED
9 years ago
6 years ago

People

(Reporter: Julien Laurent, Assigned: Bernd)

Tracking

Trunk
mozilla11
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(4 attachments)

(Reporter)

Description

9 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4

In a table with a page break occuring in a rowspan=5, spanning rows are missing
as the first spanned row. The Thead is correct though.
It's a very annoying problem for me as I don't see any easy workaround (highly dynamic content).

Reproducible: Always

Steps to Reproduce:
1.Open the link in Firefox
2.Launch print preview in landscape mode (no margins)
Actual Results:  
Rows are missing at the beginning of the second page.

Expected Results:  
10 cells with rowspan=5 and one more row (named AUTO) like the other entries.

Prints ok in IE (surprisingly o_O).
Component: General → Printing: Output
Product: Firefox → Core
QA Contact: general → printing
(Reporter)

Comment 1

9 years ago
In fact better Expected Results would be a page break before the first rowspan of the block causing the page break.
Confirmed that rows are missing. I'll attach a printed PDF demonstrating the issue.

A minimized testcase would be awesome here.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Version: unspecified → Trunk
Created attachment 351210 [details]
zipped original testcase

Here's the URL, saved & zipped, in case it goes down at some point in the future.
Created attachment 351213 [details]
printed PDF demonstrating problem.

In the 3rd column, the original page has rows labeled "Q1" through "Q6", but the printed output is missing the row for "Q4". (it jumps from Q3 on page 1 to Q5 on page 2)

Where this row should be, there's just blank space, except in the rightmost column.
I'm testing using
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1b3pre) Gecko/20081203 Shiretoko/3.1b3pre
 --> Platform=All
OS: Windows XP → All
Hardware: PC → All
(Assignee)

Comment 6

6 years ago
Created attachment 577159 [details]
reduced testcase
(Assignee)

Comment 7

6 years ago
just from code inspection:

http://mxr.mozilla.org/mozilla-central/source/layout/tables/nsTableRowGroupFrame.cpp#993

the code in SplitSpanningCells looks only for completeness but not for truncated.

So we happily split a truncated cell, but the image is not splittable
(Assignee)

Comment 8

6 years ago
Created attachment 577335 [details] [diff] [review]
patch
Assignee: nobody → bernd_mozilla
(Assignee)

Comment 9

6 years ago
https://tbpl.mozilla.org/?tree=Try&rev=cfd56e997bc0
(Assignee)

Comment 10

6 years ago
Comment on attachment 577335 [details] [diff] [review]
patch

The patch lacks a little bit content but with CVS blame its more obvious

http://bonsai.mozilla.org/cvsblame.cgi?file=mozilla/layout/tables/nsTableRowGroupFrame.cpp&rev=3.411&mark=1253,1254,1256,1261#1252

This code is from Chris :-)
Attachment #577335 - Flags: review?(dholbert)
(Assignee)

Comment 11

6 years ago
Comment 7 is bogus, it only highlights that this code was written in a hurry and is  difficult to read. But I have no idea how to do it better.
Comment on attachment 577335 [details] [diff] [review]
patch

Patch looks reasonable, given highlighted mxr link from comment 10 (thanks for that).

A few nits on the test:

>+++ b/layout/reftests/bugs/467444-1-ref.html
>+<style>
>+div.spacer {
>+             height: 5px; 
>+             width: 10px;}
>+img, td.spacer {height: 140px; 
>+                width: 30px;}
>+</style>

Nix the straggling space character at the end of the line, after both "height" declarations.  (both in testcase & reference case)

This chunk also could stand some other spacing beautification, but I won't hold you to that.

>+</html>
>\ No newline at end of file

Add newline at end of file to fix this ^^.
(affects both testcase & reference case)

r=me with the above
Attachment #577335 - Flags: review?(dholbert) → review+
(Assignee)

Comment 13

6 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/c5c36c2f1c21
https://hg.mozilla.org/mozilla-central/rev/c5c36c2f1c21
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla11
(Assignee)

Updated

6 years ago
Flags: in-testsuite+
You need to log in before you can comment on or make changes to this bug.