AB4D Forum

Full Version: How to reset without losing rotation?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Is there a way to reproduce the behavior of ResetToLimits() but keep the current rotation angle?
That is very easy. It can be done with:

ZoomPanel1.SetViewbox(ZoomPanel1.ViewboxLimits);
That worked thanks. Got another question for you: how do you zoom and pan to a specific object in your xaml? Whats the easiest way to accomplish this?
Because this problem is probably interested for other users also I have created a new thread with the solution: http://forum.wpf-graphics.com/showthread.php?tid=200
Had a small issue with this. When I apply a rotation to the zoompanel, using this mechanism to reset zoom no longer works right. It zooms as if it was not rotated. In my case I have a rectangle what will zoom differently if it is landscape vs portrait.