New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
canvas zoom and scroll with mousewheel #1659
base: master
Are you sure you want to change the base?
Conversation
|
oh shit. |
|
That's just awesome! Pd badly needs a proper zoom function... |
most canvas and item commands are covered. "itemconfigure -font" still to be processed.
11d9f63
to
6113a3a
Compare
|
"Almost" good here! |
|
I think it's about ready. |
…tting zoom if needed
simplifying the MouseWheel bindings (and prepare for Ctrl-+ resp Ctrl--)
done. Now the depth is expressed in steps, and the actual depth is |
- the "Zoom New Windows" setting is now saved to {pd_guiprefs}/default_zoom.conf
- the old .pdsettings::zoom is ignored
- LATER: allow other default_zoom values than 0(100%) or 100(200%)
better keeping immobile the content under the mouse
(and give up trying to do it on scrolling, no working solution was found)
|
This PR has been brought up to date. I would appreciate it being tested in a variety of circumstances, so that we can insist to have it included. |
|
This PR has been updated to latest master, and debugged for MacOS and Windows. |
|
I already gave many thumbs up, but I haven't come around to actually test it yet. I will put this on my list and then lobby relentlessly to have this included in Pd 0.55 :) |

Zoom and scroll with the mouse wheel, like most modern software.
The code is adapted from https://wiki.tcl-lang.org/page/Canvas+zooming+using+mousewheel.
It will also allow to clean up the GUI C code from every
IEMGUI_ZOOM()occurrences and logic ;-)Note: the current zoom factor could be reported to the Pd-core side, in order to be saved to file.