1 Reply Latest reply on Jun 2, 2015 1:55 AM by DBLjan

    Best way to find text of any kind of bold font-style

    duder54538470

      Hello,

       

      I need to find all bold text in several documents. The problem is that there is text with the '67 Bold Condensed' font style, other use'65 Bold', other '68 Bold Condensed Italic'... So I have to do one find text for each one of those styles.

       

      Is there a faster way to do this, like doing a single find that would give me all text using any kind of bold style?

       

      Thanks

        • 1. Re: Best way to find text of any kind of bold font-style
          DBLjan Level 2
          tell application "Adobe InDesign CS5.5"
              activate
              
              if not (exists active document) then
                  display dialog "Please open a document." buttons {"Bummer."} default button 1 with icon 2
              else
                  set user interaction level of script preferences to never interact
                  -- Suchabfragen speichern        
                  set oldFTP to properties of find text preferences
                  set oldCTP to properties of change text preferences
                  
                  -- Wechsel
                  set find text preferences to nothing
                  set change text preferences to nothing
                  set include master pages of find change text options to true
                  set include locked layers for find of find change text options to true
                  set properties of find text preferences to {include master pages:true, applied font:"Futura ND", font style:"Bold"}
                  set properties of change text preferences to {include master pages:true, applied font:"Myriad Pro", font style:"Bold"}
                  change text
                  set properties of find text preferences to {include master pages:true, applied font:"Futura ND", font style:"Book"}
                  set properties of change text preferences to {include master pages:true, applied font:"Myriad Pro", font style:"Regular"}
                  change text
                  set properties of find text preferences to {include master pages:true, applied font:"Futura ND", font style:"Medium"}
                  set properties of change text preferences to {include master pages:true, applied font:"Myriad Pro", font style:"Semibold"}
                  change text
                  
                  -- Suchabfragen wiederherstellen        
                  set properties of find text preferences to oldFTP
                  set properties of change text preferences to oldCTP
                  
                  
                  set user interaction level of script preferences to interact with all
                  
                  (*    set AI to all page items of active document
                  repeat with k from 1 to length of AI
                      
                      if class of item k of AI = text frame then
                          if overflows of item k of AI = true then
                              tell item k of AI
                                  fit given frame to content
                              end tell
                          end if
                      end if
                  end repeat *)
                  
                  
              end if
              
              
          end tell
          

           

          Hi Duder,

           

          as we change company font from futura to myriad, i made this one-exec/change-all script.

          I dont know if youre on an appel machine, then you can try to change the applescript to choose a folder and batch all documents.

           

          Also I dont know what you wanted to do after finde, mark, format, change…

           

          This script is for batching the text-find/change-dialog. It has one flaw: You should house the script in a tell active document-block to prevent changing in all open documents…but maybe you can use this and open all documents before execution.