Skip navigation
Studio1540
Currently Being Moderated

Change fonts using AppleScript

Jul 3, 2012 11:41 AM

Tags: #cs5.5 #indesign #indesign_cs5.5 #scripting #applescript

I want to change every occurance of a typeface to another. In QuarkXPress, the syntax was:

 

set the font of every character of every text box where font is "Zapf Dingbats" to "Times"

 

I've tried the same logic and the find/change commands but have not had any luck ... can anyone guide me on this one?

 
Replies
  • Currently Being Moderated
    Jul 4, 2012 1:40 AM   in reply to Studio1540

    You need to look for applied font

     

    tell application "Adobe InDesign CS5"

      activate

      --get name of fonts

              set someFont to some font

              tell the active document

                        set applied font of every character of every story to someFont

              end tell

    end tell

     
    |
    Mark as:
  • Currently Being Moderated
    Jul 12, 2012 12:06 PM   in reply to Studio1540

    Your glyph ID can't be text, it has to be a number, so no quote marks.

    {applied font:"Times", font style:"Regular", glyph ID:81}

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points