You'll need to grab the transformation in your event handler and apply
it's reverse to the mouse co-ordinates:
SVGMatrix trans =
((SVGLocatable)e.getTarget()).getScreenCTM().inverse();
SVGPoint point =
svgCanvas.getSVGDocument().getRootElement().createSVGPoint();
point.setX(e.getClientX());
point.setY(e.getClientY());
point = point.matrixTransform(trans);
(where e is the MouseEvent)
Now point contains the real co-ordinates that you can use to draw your
circle.
Regards,
Matthew.
On Wed, 2008-01-23 at 11:13 +0200, Cojocar Cosmin wrote:
> Matthew,
>
> How did you managed with zoom?
> Because now after I zoom in or out, and put some circles
> they're location is wrong.
>
> Regards,
> Cosmin
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]