Hi,
> I am trying to programatically zoom into an area which i know the absolute
> coordinates of.
> I searched for a way to do that, and only found this:
> 
>         AffineTransform at = new AffineTransform();
>         at.scale(scale, scale);
>         at.translate(-xStart, -yStart);
> 
>         at.concatenate(canvas.getRenderingTransform());
>         canvas.setRenderingTransform(at);
> 
> but this does not really help me since i know the exact coordinates (x1,y1,
> x2,y2) of the area i want to zoom in to.

That's exactly AffineTransform do. What you need is to calculate the
current view transform compare with the exact coordinate you want to
zoom. Then just transform scale and transform translate.

Regards
Tonny Kohar
-- 
Sketsa 
SVG Graphics Editor
http://www.kiyut.com



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to