Closed Bug 1658819 Opened 1 year ago Closed 1 year ago

Number of sheets value incorrect in new tab modal print preview


(Toolkit :: Printing, defect, P1)




82 Branch
Tracking Status
firefox81 --- verified
firefox82 --- verified


(Reporter: svoisen, Assigned: mstriemer)



(Whiteboard: [print2020_v81])


(1 file)

The "number of sheets" indicator appears to often be incorrect, whereas the numbering in the footer in the actual print preview is always correct. Generally, it looks like the value of the number of sheets indicator is always greater than the actual number that will be printed.

For instance, printing shows 13 sheets when it only actually prints as 8 sheets.

For reference, my print.print_paper_height is set to 11.

Flags: needinfo?(hikezoe.birchill)
Severity: -- → S2
Priority: -- → P2
Whiteboard: [print2020_v81]

In the new print preview UI, the frontend code supposes that UpdatePageCount event gets fired just once in response to a single updatePreview call, but in fact the event gets fired couple of times here and here.

In the failure cases, at the time the event gets fired initially, the PageSequence frame height is somewhat bigger (it's 318876 in app units in a case), then after a reflow happened (for some reasons) the event gets fired again, in the second event the total page number is correct.

I think this behavior is inevitable (given that we wait for lazy loading images, for example). In the old print preview UI, we keep listening the UpdatePageCount event until the preview preview UI is destroyed.

:mstriemer, would you mind changing the frontend code to keep listening the event there?

Flags: needinfo?(hikezoe.birchill) → needinfo?(mstriemer)
Flags: needinfo?(mstriemer)
Priority: P2 → P1

Thank you, :mstriemer!

Duplicate of this bug: 1659396
Assignee: nobody → mstriemer
See Also: → 1660938

Comment on attachment 9170796 [details]
Bug 1658819 - Wait for preview to finish before updating page size r?jwatt

Beta/Release Uplift Approval Request

  • User impact if declined: The number of sheets message will sometimes be out of sync, especially on larger pages or when making frequent settings changes.
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): This updates the new preview code to more closely match the old code.
  • String changes made/needed: No
Attachment #9170796 - Flags: approval-mozilla-beta?
Pushed by
Wait for preview to finish before updating page size r=jwatt
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 82 Branch
Duplicate of this bug: 1660938

No test, no verification in nightly, and no QA doesn't seem like a happy combination. Would be good to see this verified somehow.

Flags: qe-verify+

Reproduced this issue several times during our previous tests.

This is verified fixed using Firefox 82.0a1 (BuildId:20200827093043) on Windows 10 64bit, macOS 10.14 & Ubuntu 20.

Leaving a ni? on myself and the qe-verify + flag until this gets uplifted & verified in beta as well.

Flags: needinfo?(emil.ghitta)

Comment on attachment 9170796 [details]
Bug 1658819 - Wait for preview to finish before updating page size r?jwatt

Approved for 81.0b4.

Attachment #9170796 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Whiteboard: [qa-triaged]

This issue is verified fixed using Firefox 81.0b4 (BuildId:20200829200810) on Windows 10 64bit, macOS 10.14 & Ubuntu 20.04

Flags: qe-verify+
Flags: needinfo?(emil.ghitta)
You need to log in before you can comment on or make changes to this bug.