Hi Thomas, thank you very much, you helped a lot! I didn't think about changing currentScale and Translate... Now I'm sure, that this is the way I will get it work.
Thank you! Kai. -----Original Message----- From: Thomas DeWeese [mailto:[EMAIL PROTECTED] Sent: Dienstag, 16. November 2004 03:02 To: Batik Users Subject: Re: Resized viewBox Attribute Hi Meves, As far as I can tell this is working just the way it is supposed to. In particular it's important to understand that there are several levels of transform involved here. There is the transform from viewBox->window W/H and on top of that is the transform due to currentScale/Translate, which is manipulated by scroll and zoom. With the current code if you also reset currentScale/Trans you will get more or less what you want: SVGSVGElement svg; svg=(SVGSVGElement)svgDocument.getRootElement(); svg.setAttribute("viewBox","30 30 30 30"); svg.setCurrentScale(1); SVGPoint pt = svg.getCurrentTranslate(); pt.setX(0); pt.setY(0); However, it is important to be aware that there is a clip associated with viewBox and window W/H. This can be overcome by setting overflow to visible. However I think that what you really want to do is 'bite the bullet' and manipulate the currentScale/Translate to set the view where you want it. Good luck! --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]