• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Illustrator scripting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Illustrator scripting


  • Subject: Re: Illustrator scripting
  • From: Shane Stanley <email@hidden>
  • Date: Sun, 22 Jan 2017 13:04:28 +1100

On 22 Jan 2017, at 12:40 pm, Jean-Christophe Helary <email@hidden> wrote:

The problematic script is the following:

Try this. It should avoid the need to ungroup:

tell application id "com.adobe.illustrator" -- Adobe Illustrator
tell document 1
set theSel to selection
my addVariablesFor:theSel
end tell
end tell

on addVariablesFor:listOfItems
tell application id "com.adobe.illustrator" -- Adobe Illustrator
tell document 1
repeat with anItem in listOfItems
set theClass to class of anItem
if theClass is text frame then
set theVar to make new variable at end with properties {kind:textual}
set anItem's content variable to theVar
else if theClass is group item then
(my addVariablesFor:(page items of anItem))
end if
end repeat
end tell
end tell
end addVariablesFor:

-- 
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>, <latenightsw.com>


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Illustrator scripting
      • From: Jean-Christophe Helary <email@hidden>
References: 
 >Illustrator scripting (From: Jean-Christophe Helary <email@hidden>)
 >Re: Illustrator scripting (From: Shane Stanley <email@hidden>)
 >Re: Illustrator scripting (From: Jean-Christophe Helary <email@hidden>)

  • Prev by Date: Re: Illustrator scripting
  • Next by Date: Scripting the macOS Spelling Dictionary
  • Previous by thread: Re: Illustrator scripting
  • Next by thread: Re: Illustrator scripting
  • Index(es):
    • Date
    • Thread