Hi fireball,

On Nov 1, 2012, at 11:19 AM, fireball <samiib...@hotmail.com> wrote:

> I am using AffineTransform to rotate SVG elements but as far as I understand
> it only provides two methods to rotate. One sets it identity matrix with a
> rotation (setToRotation(theta)) and another rotates by a delta
> (rotate(theta)).
> 
> What I want to do is set rotation to specific angle. I.e. I don't want to
> set its matrix to identity matrix nor do I want to rotate by delta.

        The first method sets it to a specific rotation, not an identity matrix 
so it seems that is what you
want.


> I want to be able to set rotation like we can by setting 'rotate' attribute. 
> Is
> there a way to do it using AffineTransform or another API?

        setToRotation does exactly what the 'rotate' function' does in the SVG 
transform attribute.

        I'm a little afraid that you are trying to adjust a general affine 
transform (that may have non-uniform
scaling and skew) so that it has a specific rotation. I'm afraid that is what 
you want to do because you can't 
really do it without coming up with a perhaps non-sensical definition of 
rotation...

        Thomas
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-h...@xmlgraphics.apache.org

Reply via email to