Skip to main content
Inspiring
June 19, 2020
Question

script access to transformation frame

  • June 19, 2020
  • 3 replies
  • 1156 views

Hi,

 

is there a way to detect transformations applied to an object? In the UI, I can just rotate / scale / shear art items, and until I reset transformation frame, I can see how the object was transformed. I would like to do that from a script.

It seems there is no script access - could the matrix be accessed from an SDK plugin?

This topic has been closed for replies.

3 replies

renél80416020
Inspiring
June 24, 2020

Bonjour!

Pour ce qui est de la rotation et BBAccumRotation,

On le reconnaît d'après le rectangle de sélectoin:

Lobjet rouge PathItem
Tag: (BBAccumRotation , 0.785398)

L'objet bleu PathItem

No tag

De elleere j'ai toute une série de scripts sur ce sujet me contacter par mail.

 

 

MilosR
Inspiring
June 24, 2020

Тако је пријатељу, све смо ми тебе разумели.

 

Лепо сам написао да понекад Илустратор не враћа податак о ротацији или смицању објекта. Mоже да се деси да податак о извршеној трансформацији не постоји, свакако ниси нам дао детаљан опис свог проблема.

MilosR
Inspiring
June 25, 2020

Salut MilosR

Il semblkerait que tu as de gros problèmes ?

 


My friend, I am willing to help, and how can I help you if i do not understand you. I do not have a problem if you write in your own language, but you see that here we talk in English. I did same thing you did, that's all, write in my own language. You can always create a new thread and use any language, i wont complain. What the discussion would look like if everyone posts in their own language.

 

pixxxelschubser
Community Expert
Community Expert
June 23, 2020

Hi @birnerseff,

maybe here you will find some more informations.

How to get the angle of an object ? 

MilosR
Inspiring
June 22, 2020

Illustrator stores applied skew angle and rotation angle inside dictionaries, you can access dictionary entries using Dictionary suites (using SDK), I am not sure about scripting, but there is probably an option there too.

 

Search for following Dictionary keys: BBAccumRotation, BBAccumShear.

 

Hovewer, in some cases Illustrator does not store those values, not sure why (i think it is the case when you apply transformations using transformation panel), and depending on object there is no way to get transformation matrix.

 

For example, if user creates path art (rectangle) and then apply skew transformation using transform panel (shift+f8) Illustrator first do expand, then transform points of path, this is now new transformed path object with new points, to get original path you need to have angle to apply inverse transformation, but you cannot get applied skew angle using SDK. In this case neither user can reset transformation.

 

https://community.adobe.com/t5/illustrator/script-access-to-transformation-frame/td-p/11220995?page=1