How can you zoom without the mouse wheel?

How can you zoom without the mouse wheel?
I need a button to appear when zooming and I have thought to do the zoom by hand but I don’t know how to do it with the api. Is there a way to tell when it zooms in?

There is no way to zoom with keyboard at this point but a feature request has been added to our backlog. However, you can use the arrow keys for panning, simply turn off the Disable Key Pan toggle in your model settings.

I mean via api, a command to increase or decrease zoom.

There is a cameratarget command in python, maybe you could use that?
(I don’t know how to do it in grasshopper as I only program in scripts)
You could make a vector from camera to target, unify it’s length and set the new camera position to current location + scaled unified vector to move the camera x units closer to target. (And do the same with the target if you want to be able to move camera past the target position)

You can update the camera position with the updateAsync() method, see the API reference for details:

For the heck of it I opened a small file in V7 typed in “z” then "f’ then “.75” and zoomed to 75% of the original size seen on screen so it appears to me that in fact keyboard zooming works fine in V7.