xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fireball <samiib...@hotmail.com>
Subject Re: How to set rotation using an existing API
Date Mon, 05 Nov 2012 13:28:52 GMT
No it doesn't. It does not maintain the matrix. Here is an example,

/Original matrix:/
matrix(2.0, 0.0, 0.0, 2.0, 300.0, 300.0)

/Apply rotate(Math.toRadians(30)):/ *<-- This one is OK but I cannot use it
because it adds 30 and not set to 30*
matrix(1.7, 0.9, -0.9, 1.7, 300.0, 300.0) 

/Apply setToRotate(Math.toRadians(30)):/ *<-- This one is not good because
it does not maintain my original location. Plus, it should have not changed
the matrix at all because it is resetting to 30 again.*
matrix(0.8, 0.4, -0.4, 0.8, 0.0, 0.0) 

I guess my only option is to do some logic myself like finding the screen
location of the element before applying the rotation and then resetting the
location after?



--
View this message in context: http://batik.2283329.n4.nabble.com/How-to-set-rotation-using-an-existing-API-tp4655329p4655342.html
Sent from the Batik - Users mailing list archive at Nabble.com.

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


Mime
View raw message