Is there an event like "BeginChartZoom"?

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
huy
Newbie
Newbie
Posts: 22
Joined: Fri Dec 29, 2006 12:00 am

Is there an event like "BeginChartZoom"?

Post by huy » Fri Nov 09, 2007 7:50 am

Hi,

I am not sure if there is a way to limit zooming in when the graph is already zoomed in too many times. By "too many times" I mean the state at which further zooming in just can't change axis limits at all. Why? Because when we have already zoomed in enough times, the x-axis are labeled the same for every label on the x-axis, and similar for the y-axis. I think axis.minimum and axis.maximum are equal at that time in TeeChart. So it is not very useful to allow the user to continue to drag-and-zoom any more.

In your opinion is it possible to implement the above requirement? In summary, it means: if (axis.maximum - axis.minimum < some constant DISSALLOWED_ZOOM) then do not allow the user to zoom in any more, and just allow the user to zoom out only.

By the way, I was thinking of the event Mouse Up, but I don't know between Mouse Up and Zoomed event, which one is triggered first? I believe that Mouse Up is triggered before Zoomed, is that right?

Thank you.
Huy

huy
Newbie
Newbie
Posts: 22
Joined: Fri Dec 29, 2006 12:00 am

Post by huy » Fri Nov 09, 2007 9:44 am

Sorry I have done a workaround for this issue. In the Zoomed event, I check if the axis.maximum - axis.minimum is too small then I set axis maximum and axis.minimum to orginal values which were stored just before the Zoomed event occured (in MouseDown event).

Regards.
Huy

Post Reply