Fix Issue 254: Handle Webkit's use of matrix transforms, merging Peter's patch
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@752 eee81c28-f429-11dd-99c0-75d572ba1dddmaster
parent
17ab1563d3
commit
aacc77b6a6
|
@ -3572,6 +3572,11 @@ function BatchCommand(text) {
|
|||
var xform = tlist.getItem(t);
|
||||
if (xform.type == 4) {
|
||||
return xform.angle;
|
||||
} else if (xform.type == 1) {
|
||||
// Matrix transformation. Extract the rotation. (for Webkit)
|
||||
var angle = Math.round( Math.acos(xform.matrix.a) * 180.0 / Math.PI );
|
||||
if (xform.matrix.b < 0) angle = -angle;
|
||||
return angle;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue