Zotero PDF reader (sometimes) zooming out the pdf when fast scrolling with mouse

edited August 20, 2023
I've noticed an issue when scrolling quickly through PDFs i on my Mac. Sometimes when I rapidly scroll with my mouse, the PDF will suddenly zoom out instead of scrolling up or down the page.

This seems to happen randomly - most of the time scrolling works normally, but occasionally it will zoom out even though I'm not using any keyboard shortcuts like ctrl/cmd + scroll. I've seen this behavior with my Logitech mouse on both macOS 13 and the latest macOS 14 public beta 3. It happens in the latest 7.0.0-beta build and previous betas.

The zooming doesn't seem to occur when I use the trackpad to scroll, only with the mouse scroll wheel. I haven't been able to pinpoint what exactly triggers it to zoom instead of scroll. I'll continue testing to see if I can identify a pattern or specific actions that cause the unintended zooming. Let me know if any other details would be helpful in troubleshooting this issue.
  • I can't reproduce that. Waiting for more details and/or other people confirming this.
  • edited August 22, 2023
    thanks for reply!
    I didnt managed to consistently pinpoint it but I think I might some cues (however they might be the false flag);

    The problem seems to occur more often when:

    - Opening large, heavy PDFs like theses or OCRed documents
    - Having multiple tabs and applications open (my system has 16GB RAM with 82% in use and over 10GB swap file)
    - My SSD is over 90% full and needs cleaning
    - I didnt restarted Zotero fro, some time and I am running it more than several days/ from before waking up system from sleep; after fresh restarting app I don't get this behaviour even the other condition are satisfied (at least so far this is my observation)

    The behavior goes as follows:

    - I open a PDF in the Zotero tab (or return to already opened) and begin slowly scrolling through pages
    - After scrolling 1-2 pages or sometimes more, the PDF stops reacting to scroll inputs (for less than 1sec)
    - When I continue trying to scroll, it is instead interpreted as minimize/maximize commands depending on scroll direction (this all happens really fast, but there is visible stop moment between scrolling and maximizing/minimizing)

    If I stop scrolling and start again, it goes back to scrolling the document normally

    There are extended periods when this doesnt happen at all even with soem load, and the it another day it could happens every 1 in 5 or 1 in 10 pdfs

    I can test with Zotero 6 with the same documents and use it as my daily driver if this behaviour is present there.
  • edited August 22, 2023
    When I cause pdf-preview in built-in zotero reader to stutter/stop while scrolling and continuing to scroll then I am 100% percent times reproducing "zooming via scrolling".

    The problem is that "stuttering" doesnt happen so often and in non-deterministic way, easiest way to cause this:

    - load many (20-30 and more) long files as tabs in Zotero, have not enough ram/swap file write in/write out(?) , then starting slow scrolling sometimes is enough to induce it

    - scrolling behaviour related (around 30 s to sevaral minutes of different (varying) patterns of scrolling I able to get usually this behaviour)
    + I scroll slowly/fast and by change the direction of scrolling I am sometimes able to induce this behaviour
    + scroll/short stop/further scroll also sometimes works

    Example of this behaviour when scrolling (previously trying to record I didnt get any such behaviour through 5 min time limit on loom, here is within 15 seconds, all behaviour is caused only via mouse scroll - Logitech MX Verical, I can test another mouses as well)
    https://www.loom.com/share/ef3d0fd21eb8439bbe491a38612ca40e?sid=11abf0de-d35c-46cc-9dca-99c99d4e1772

    Here debug log from another similar incident ( 15 secunds of scrolling, after I induced zooming in/out I submitted the log D1744833961

    I use touchpad much less often, but it seems to didn;t have this kind of problem, but it might be related to dynamics of scrolling, on touchpad is much harder to do such abrupt stop and return to scroll or change of direction of scroll, but I didnt thoroughly tested it)


    I am not sure if this mighr started with beta 29 and improved reader, but even if this was earlier happening I didn't notice it so often I think
  • Would it be possible, for you, to test with a different mouse?
  • I will try test other mouses!

    Meanwhile, I was trying to disable zooming out and and in with mouse using firefox config within Zotero and set

    mousewheel.with_control.action
    mousewheel.with_meta.action

    values to 1 (instead of default 3)

    >The value 0 means “Do nothing”, 1 means “Scroll contents”, 2 means “Go back or forward in the history”, 3 means “Zoom in or out the contents”

    https://support.mozilla.org/bm/questions/1253302

    But this doesnt seems to have any effect on Zotero behaviour with pdf
  • edited August 23, 2023
    Also the issue might be more systemwide with MacOS and some apps and Logitech mouses at least (as I read on internet about it).
    I am not 100% sure but I might be able to trigger zooming by scrolling in the terminal in VSCode.

    thats why I want to completely disable scrolling with mouse (it was also disabled by default in some of the latest stable firefox releases)

    Unfotunely Zotero doesnt honour my changes and it still zoom in/zoom out when scrolling with keys while both of these setting are to set to 1 (scroll content).

    So if this is not implemented yet I would like that user would be able to change the behaviour of Zotero scrolling using those following settings.
  • I used Linux with Zotero beta for a day with the same mouse and library, didnt experienced any problem

    The Logitech mouses has varied history of support on MacOS, especially with Apple Silicon

    I think that having the ability to disable/scrolling with cmd/ctrl (on par with Firefox) might fix the issue
  • (I've never seen this with two different Logitech mice on Apple Silicon, for what it's worth.)
  • edited August 25, 2023
    I'm not sure if this is relevant, but I wanted to mention an issue with the Logitech Option+ app. When using this app on MacOS computer I use the buggy instance Zotero, I'm unable to change the scrolling on my MX Master 3 mouse from ratcheted to free wheel mode. This mouse is also causing Zotero to zoom in/zoom out while scrooling.
    So there is something buggy going on :)

    I will test wired usb mouses later this week.

    With other PDF readers with disabled cmd/ctrl + scrolling, I dont experience this kind of issue. I might test pdf.js in Firefox both with

    mousewheel.with_control.action
    mousewheel.with_meta.action

    disabled and enabled to compare.
  • edited August 27, 2023
    When using this app on MacOS computer I use the buggy instance Zotero, I'm unable to change the scrolling on my MX Master 3 mouse from ratcheted to free wheel mode.
    I use the auto-switching mode (SmartShift) with my MX Master 3, and going from ratcheted to free-spinning works normally for me in the reader.

    You should make sure you have the latest version of Options+.
  • Yes, I have the latest Option+; unfortunately I am stuck in ratcheted mode and the button to do that doesn’t work


    I will create separate issue/post about settings for changing scrolling behaviour that doesn’t work or aren’t implemented yet,

    mousewheel.with_control.action
    mousewheel.with_meta.action

    as this might solve my issue and will be much easier to reproduce

    Zotero doesnt honour my changes and it still zoom in/zoom out when scrolling with keys while both of these setting are to set from 3 (default value, zoom) to 1 (scroll content).

  • This not document outside Mozilla pages but I still would like to see possibility of such adjustement in Zotero
  • Sorry, we wouldn't have any control over those settings and wouldn’t make that configurable on our own. You should fix the actual problem with your mouse, not look for some sort of workaround in Zotero.
  • This is not just a workaround in Zotero, but a separate issue Zotero not handling user settings regarding preferred pdf.js scrolling behaviour with keys .
    There was similar bug in pdf.js that was fixed in 2015
    https://github.com/mozilla/pdf.js/pull/6073


    Whether it is a bug (or change within upstream pdf.js - Zotero fork is on par with main pdf.js version regarding this variable https://github.com/search?q=repo:zotero/pdf.js supportedMouseWheelZoomModifierKeys&type=code or feature that is not implemented because of time constraint and different priorities of the dev team I am leaving this to the team.


    If this is behaviour is intended, or due to other constraints is not possible to enable users to modify mousewheel with meta and ctrl behaviour prefs, I will not pursue this issue further, and try to experiment with mouse, fixed support to the mouse et cetera

    Thanks for your time within this discussion and the value the Zoter dev team are providing with Zotero!

    Additionally I would propose to update the shortcut section of the doc page https://www.zotero.org/support/kb/keyboard_shortcuts#pdf_reader with adding ctr/cmd + scrolling
Sign In or Register to comment.