Hi Ben,
I posted a similar request on Apple's AppleScript Users Forum. I can't find the thread at the moment, but here's the code that others helped me to develop.
You'll need to download Satimage.osax for the maths functions from here: http://www.satimage.fr/software/downloads/Satimage331.dmg/
I'd be interested to see your code.
Simon
-- SCRIPT --
tell application "Adobe Illustrator"
set {theta_deg, hscale, vscale, skew} to my decodeMatrix(matrix of text frame 1 of document 1)
end tell
on decodeMatrix(mat) -- requires Satimage.osax
tell application "Adobe Illustrator"
set _a to mvalue_a of mat
set _b to mvalue_b of mat
set _c to mvalue_c of mat
set _d to mvalue_d of mat
end tell
set theta to atan2 {_c, _d}
set cos_theta to cos (theta)
set hscale to roundThis(_a / cos_theta, 2)
set vscale to roundThis(_d / cos_theta, 2)
set skew to roundThis(_c / cos_theta, 2)
set theta_deg to roundThis(theta / pi * 180, 2)
return {theta_deg, hscale, vscale, skew}
end decodeMatrix
on roundThis(n, numDecimals)
set x to 10 ^ numDecimals
tell (n * x) to return (it div 0.5 - it div 1) / x
end roundThis
-- END SCRIPT --
... View more