-
Notifications
You must be signed in to change notification settings - Fork 159
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
Improve zooming feature with logarithmic scale #677
base: master
Are you sure you want to change the base?
Conversation
Excellent idea! I would still like a separate slow-zoom mode, but this is great. |
Okay, so I've added another option called While |
db83b2f
to
10d838e
Compare
Thank you for making this better 😄 |
Zooming now uses a logarithmic scale, and the events for zooming in/out gravitate to powers of 2, such as 50%, 100%, 200%, etc. The option `--zoom-step` has been changed to represent the number of zoom steps between powers of 2, with the default being 3 steps.
While `--zoom-steps` is the number of button or key presses between powers of 2, `--zoom-rate` represents the number of pixels between powers of 2 that the user clicks and drags between, so if you added the arg `--zoom-rate=1024`, it would result in a very slow zoom mode. The default is 128 pixels.
Zoom-mode now zooms on a logarithmic scale, and the events for zooming in/out gravitate to powers of 2, such as 50%, 100%, 200%, etc.
The option
--zoom-step
has been changed to represent the number of zoom steps between powers of 2, with the default being 3 steps.The number of zoom steps is optional, while the rate of zoom-mode uses a constant rate that is not affected by zoom steps.
Edit: You can also step between powers other than 2. For example, if you want 5 steps between powers of 3, you would enter the raw value of
ln(2) / ln(3) * 5
which results in:--zoom-step=3.154648768