My cat sat on my keyboard for a while and I came back to see my laptop screen being pure white. It remained that way even after a reboot. I later realized that my cat must've held the Super+Plus key combo for a while, and increased the zoom factor to absurd values, so I was just seeing a single pixel. And, apparently, the zoom factor persists across sessions. My `.config/kwinrc` contained these lines: [Effect-zoom] InitialZoom=19659025508.39898 Easy to fix by removing these lines and restarting, or by simply pressing Super+0. But, this shouldn't have happened in the first place. My proposal is to set a maximum value for the zoom factor, perhaps 10 is reasonable. Also I question the utility of persistently storing the zoom value.
I believe 10 is too small for some visually impaired people. Anyways if your cat sat on your keyboard it could have done many things, including deleting everything. So it is not something that we can guard against...
I think having *some* limit would definitely be reasonable
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/5591
Git commit 485769ddd90013bffd9ff578559231a17f77ad7f by Xaver Hugl. Committed on 10/04/2024 at 11:26. Pushed by zamundaaa into branch 'master'. plugins/zoom: limit the maximum zoom value to 100 Accidental changes in zoom can become very time consuming to undo otherwise. With a value of 100, you can still zoom in far enough to only see a few pixels on the screen, so it shouldn't break any actual use cases M +1 -0 src/plugins/zoom/zoom.cpp https://invent.kde.org/plasma/kwin/-/commit/485769ddd90013bffd9ff578559231a17f77ad7f
Thank you! It's a minor thing, and I agree that a limit of 10x would've been too low, I've since learned that some users do indeed rely on higher zoom levels. But, zooming to the scale of a fraction of a pixel just makes the desktop not usable to anyone, so I appreciate that it's guarded against.