A perhaps easier way to do this is transform="translate(-100,-50),scale(1.5)"
or in your case: shape1.setAttributeNS(null,"transform","translate("+positionx+","+positiony+"),scale("+scaleLevel+")"); The trick here is that the transformations are performed from right to left, so you may have to do some arithmetic to get things in the right place. DD > Hi achio, > I believe that you can use transform (matrix). The matrix command allows > you > to combine all transform commands on a single line. Read about it here: > http://www.w3.org/TR/SVG/coords.html#TransformAttribute > <http://www.w3.org/TR/SVG/coords.html#TransformAttribute> > :-) > Hi all... > I would like to ask whether it is possible to combine transform (scale) > and transform (translate) in 1 javascript statement? > For example: > > shape1.setAttributeNS(null,"transform","scale("+scaleLevel+")"); > shape1.setAttributeNS(null,"transform","translate > ("+positionx+","+positiony+")"); > ----- To unsubscribe send a message to: [EMAIL PROTECTED] -or- visit http://groups.yahoo.com/group/svg-developers and click "edit my membership" ---- Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/svg-developers/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/