Zoom bar use tip

Post your Gambas programming questions here.
Post Reply
User avatar
Cedron
Posts: 156
Joined: Thursday 21st February 2019 5:02pm
Location: The Mitten State
Contact:

Zoom bar use tip

Post by Cedron »

Here is a statement that I put in a ScrollBbar to control the Zoom property of an ImageView:
TheImageView.Zoom = Exp((TheScrollBar.Value - 50) * 0.6)
The same distance on the scroll represents the same multiplication factor. You can vary the midpoint (50 on the default ScrollBar range of 0 to 100), which varies the end cases, and you can vary the extent by changing the multiplier (0.6).

This combination of controls is so helpful.

Ced
.... and carry a big stick!
Post Reply