Pinch to Zoom on built-in PDF viewer is not a smooth zoom and uses large jump
Categories
(Firefox :: PDF Viewer, enhancement)
Tracking
()
People
(Reporter: sraghuvanshi, Assigned: kats)
References
(Blocks 1 open bug)
Details
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:79.0) Gecko/20100101 Firefox/79.0
Steps to reproduce:
I am on Windows 10. I have the following about:config settings enabled:
apz.windows.use_direct_manipulation to true
apz.allow_zooming to true
Open a PDF file using the built-in PDF viewer. Then, try to pinch to zoom on a precision trackpad.
Actual results:
The zooming is extremely choppy and laggy, and when it has loaded the document has zoomed by a huge increment.
Expected results:
Compare it to the old Microsoft Edge PDF viewer (not the new Chromium-based Edge), where pinching to zoom in and out is butter-smooth.
Reporter | ||
Updated•5 years ago
|
Comment 1•5 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Assignee | ||
Comment 2•5 years ago
|
||
We'll likely have to fix in the PDF viewer, across all platforms.
Reporter | ||
Comment 4•5 years ago
|
||
It's possible that they are related, but bug 1625462 does not occur for me. In particular, when I pinch to zoom on a PDF, the zoom percentage displayed by PDF.js changes, but the UI elements (like the top bar displayed by PDF.js) do not get zoomed as well. Only the PDF content changes.
However, no matter whether I pinch in or out, the PDF zooms in. I cannot ever zoom out using just the trackpad gestures. Should I file a separate bug for that?
Comment 5•5 years ago
|
||
I see it on mac too.
Updated•5 years ago
|
Reporter | ||
Comment 6•5 years ago
|
||
I created Bug 1643461 for the separate issue that I cannot zoom out (only in) using the trackpad.
Comment 7•5 years ago
•
|
||
Just a note: with apz.allow_zooming enabled, bug 1619187 is what changed the behaviour here from pinch zooming the whole page including the pdf.js controls into this bug.
With apz.allow_zooming disabled we always did the distinct steps zoom, but it gets much more sensitive (ie more zooming with the same physical motion) with apz.allow_zooming enabled.
Comment 8•5 years ago
|
||
Presumably pdf.js is listening to ctrl+scrollwheel msgs and the ctrl+scrollwheel msgs we create from pinches have more change in them then the ones that the OS was generating for us? Is that a wider issue that we need to look into outside of just pdf.js?
Assignee | ||
Comment 9•5 years ago
|
||
pdf.js's zooming code was already pretty far out of whack, so I wouldn't use it as a good baseline to check for potential defects in our ctrl+scrollwheel messages. See e.g. https://github.com/mozilla/pdf.js/issues/8802
Comment 10•4 years ago
|
||
The severity field is not set for this bug.
:bdahl, could you have a look please?
For more information, please visit auto_nag documentation.
Updated•4 years ago
|
Comment 11•4 years ago
|
||
Same on MacOS 10.15.5. Crazy zoom. Can it be fixed ever? Having it since two months. Once apz.allow_zooming enabled and it goes bonkers.
Assignee | ||
Comment 12•4 years ago
|
||
The PR for bug 1392361 should fix this one too.
Reporter | ||
Comment 13•4 years ago
|
||
Bug reporter here. While I applaud the improvements that the PR for bug 1392361 bring, I still don't think this bug is fixed by that. While the touchpad zoom increment has decreased, it is still not smooth. Try zooming on a PDF in Chrome's builtin PDF viewer or Safari to see what I'm talking about.
Assignee | ||
Comment 14•4 years ago
|
||
That's true, this bug is only intended to address the big jump part. The zoom will still be "stepwise" rather than smooth because pdf.js doesn't currently have an easy way to hook up smooth zooming. But the PR will at least reverse any regressions that were caused by the introduction of APZ zooming (i.e. the big jumps in zooming).
Assignee | ||
Comment 15•4 years ago
|
||
I filed bug 1659492 to implement a smooth zoom in pdf.js, although I don't plan on working on it in the near future. I'll dupe this bug to that one to avoid confusion since there were two different issues lumped into this one, and one of the issues is getting fixed by bug 1392361.
Description
•