Printing from PDF.js or exporting PDF using B&W mode rasterizes output at low quality
Categories
(Core :: Printing: Output, defect, P1)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr68 | --- | unaffected |
firefox-esr78 | --- | unaffected |
firefox80 | --- | wontfix |
firefox81 | --- | fixed |
firefox82 | --- | fixed |
People
(Reporter: svoisen, Assigned: emilio)
References
(Regression)
Details
(Keywords: regression, Whiteboard: [print2020_v81] [old-ui+])
STR
- Open any PDF document in Firefox and view using PDF.js. For instance, I used the CA DMV form found here: https://www.dmv.ca.gov/portal/uploads/2020/06/reg135.pdf
- Click the print button from the viewer interface.
- Print to a physical printer.
Content seems to be rasterized at low quality. Text is blurry and pixelated.
Regression Info
Running mozregression (that was a fun waste of paper!) gives the following:
Last good revision: 432e42cbbc4139efd2319952ec33efe8ff9add3c
First bad revision: 35cdd8678bbfed2d652deb2d7105494e366f1a0e
Reporter | ||
Updated•5 years ago
|
Reporter | ||
Comment 1•5 years ago
|
||
This looks like it was regressed by bug 1659753. I don't see anything else that stands out in the list.
Comment 2•5 years ago
|
||
I don't see how that patch would have changed print behavior. There are a number of print related changes in that changeset that look suspicious. FWIW, when regressions like this have happened in the past, it's been in gfx code e.g. using the wrong surface type or performing operations on a surface that cause it to be rasterized.
Reporter | ||
Comment 3•5 years ago
|
||
All of the print changes in the changeset are frontend related, so they don't seem to be the issue.
That said, "performing operations on a surface that cause it to be rasterized" is a good hint. In the new print preview UI, selecting "Black and White" mode is what is causing the problem (Color works fine). I believe we apply a filter to the cloned document to apply the B&W affect. Oddly, I don't see that in the changeset, so maybe something went wrong with mozregression.
Emilio: I think you worked on the B&W filter in bug 1631449. Thoughts?
Updated•5 years ago
|
Reporter | ||
Updated•5 years ago
|
Reporter | ||
Comment 5•5 years ago
|
||
It appears that even if you print using the system dialog (going through the new tab modal) and the print preview was rendered using B&W, you also get low print quality. See bug 1660784.
Comment 6•5 years ago
|
||
I checked what Chrome does here and I don't see the Color option for macOS at all (save to PDF or physical printer).
On Windows, I did see that the printed PDF in Nightly is blurrier using B&W mode.
Assignee | ||
Updated•5 years ago
|
Comment 7•5 years ago
|
||
Set release status flags based on info from the regressing bug 1631449
![]() |
||
Updated•5 years ago
|
Assignee | ||
Comment 8•5 years ago
|
||
Black and white quality issues should be fixed in bug 1660857. Should we leave this for PDF.js?
Comment 9•5 years ago
|
||
This seems to affect the old ui as well.
Reporter | ||
Comment 10•5 years ago
|
||
Reminding myself to retest this with and without PDF.js.
Reporter | ||
Comment 11•5 years ago
|
||
I can confirm this is resolved in both old and new UI with the fix for bug 1660857.
Updated•5 years ago
|
![]() |
||
Comment 12•5 years ago
|
||
Bug 1660857 was uplifted to beta 81.
Description
•