fix export bug with negative scale

Grapefrukt incorrectly extractes a scale value from transformation matrix in the export to xml.
When scale is negative, in xml exported positive scale value and wrong rotation value.

Correct formulas for extracting offset, rotation and scale values ​​from transformation matrix can be found here - http://math.stackexchange.com/questions/13150/extracting-rotation-scale-values-from-2d-transformation-matrix