Lesson D: Find/Change Turned Up to 11

Find/Change is such an important time saver in InDesign that I dedicated an entire chapter of the Compendium to it. There you will find the following examples reiterated, along with some other examples as well. I also provide some additional resources, especially for grep searches.

  • In the downloaded document called 7 Long Documents.indd, go to pages 8 and 9 and fit that spread in the window (-option-0/Ctrl-Alt-0).

GREP: Find Patterns, Locations, and More

Long ago, when I had the honor of running the Seattle InDesign User Group (the world’s first!), I was given the list of the approximately 800 members it had at the time. Like the first list of names on page 9, the list I had was not written with last names first nor was it alphabetized. I knew of a fast way to sort the names alphabetically once they were formatted correctly, but I had to get the last names, or surnames, first. So I did my first GREP Find/Change.

  • Get the text cursor blinking anywhere in the first text frame on page 9. This should set the scope of the search to that story.
  • Summon the Find/Change window: Edit > Find/Change or -F/Ctrl-F. Click the GREP tab, then be sure that the Search menu (about halfway down) is set to Story.

There is a description of our query’s logic on page 8. In short, we need a way to bring the last chunk of letters in each paragraph (presumably a surname) to the beginning of the paragraph and insert a comma after that chunk. Delimiting “chunks” in the GREP Find What field is done with parentheses. To move those chunks around in the Change To field requires us to reference them by the order in which they’re found (“$1” for the first chunk, “$2” for the second, etc.). Thus:

  • In the Find What field, carefully type: (.+) (.+)

See page 8 (and the Compendium) for a translation of that and…

  • In the Change To field, carefully type: $2, $1
  • Click the Change All button.

Feels pretty good, eh? Recall that I had 50 times as many names suddenly formatted properly. That’s when I realized I wanted to get to know grep better.

To sort the list, we’ll use a script. Scripts are bits of programming, most often in JavaScript, that extend what InDesign can do. Although I am not going to cover JavaScript scripting in this book, there are many resources for those interested in learning that skill. A web search for “InDesign scripting” will yield the best ones quickly.

But InDesign comes with some sample scripts that come in handy once in a while. We’ll use the one to sort paragraphs alphabetically.

  • Save the document (-S/Ctrl-S).

A script may perform many operations, possibly hundreds. Undoing those can be time-consuming. So I always save before using a script so that, if it fails me, I can use File > Revert to get back to the last saved state quickly.

  • Get the Scripts panel: Window > Utilities > Scripts. In that panel, you’ll see two folders: Application and User.
  • Click the disclosure arrow next to Application, then the one next to Samples, then, finally, the one next to Javascript. To see the long list of scripts, you may wish to make the panel taller.
  • Highlight all the text in the frame that you just reformatted. Five clicks or -A/Ctrl-A will do that.
  • Far down the list of scripts, locate and double-click on the script called SortParagraphs.jsx.
  • In the dialog box that opens, you can choose the option to Ignore Formatting (faster). The style applied to those names won’t be lost.

Find/Change Glyphs

Many fonts come with more glyphs than some users realize. There may be many glyphs of a particular character (a handwriting font may have many versions of an “e,” for example). There might also be ornaments and swashes. But how do we type them? In InDesign, we look in the Glyphs panel, find the glyph we want, then double-click it. It is then inserted where our cursor has been blinking.

But there’s another feature that involves the Glyphs panel and glyphs in general: finding one glyph and replacing it with another.

  • In the second text frame on page 9, select (highlight) one of the bullet glyphs, but not the space that follows it.
  • Right-click and choose Load Selected Glyph in Find. When you do so, Find/Change opens in its Glyphs tab with a bullet shown in the Find Glyph window.
  • Click elsewhere in that frame with the Type tool so that text is no longer highlighted, but the story can still be targeted for the search.
  • Get the Glyphs panel: Type > Glyphs. I’d like to choose an ornament from a font that has some from which to choose.

The Glyphs panel has a Show menu that limits which characters you are shown. The font currently in use does not possess any ornaments, or that would be a choice in the Show menu.

  • At the bottom of the Glyphs panel, choose a different font (I will choose Kepler Std) then check the Show menu. If Ornaments is listed, choose it.

It may be hard to see in longer lists. Alternately, you can choose a font that contains nothing but ornaments, like the classic Zapf Dingbats.

  • Highlight a glyph that might make a fun replacement for a simple bullet.
  • Right-click it and choose Load Glyph in Change.
  • Take a look at the Find/Change window and make sure the Search menu in Find/Change is set to Story, then click the Change All button. You should now be enjoying your new, fancy bullets.

Find/Change Object Formatting

Optimally, objects, like the shapes we draw in InDesign, will be formatted with object styles. Sometimes we forget to use them, or sometimes an object gets disassociated from its style. So, for some reason, we can be left with many objects whose appearance we’d like to change quickly.

If the objects to be changed have some attribute(s) they share with each other, but that are not shared with anything else in the document, we can use Find/Change. This is the case for the objects on the right side of page 9. They all have a 5-point stroke weight and nothing else in the document does.

  • Be sure nothing is selected (-shift-A/Ctrl-Shift-A).
  • Summon the Find/Change window: Edit > Find/Change or -F/Ctrl-F.
  • Click the Object tab and then check that Search is set to Document.
  • To set the attribute to look for, click in the rectangular field below Find Object Format.
  • On the left side of the Find Object Format Options dialog that just opened, go to Stroke.
  • In the Weight menu, choose 5 pt. Recall that this is the attribute the objects share with one another, but with no other object in this document.
  • Click OK.
  • To set the attribute you would like to change to, click in the rectangular field below Change Object Format.
  • We can change to anything we like, but let’s just change the stroke weight for now. On the left side of the Change Object Format Options dialog that just opened, go to Stroke and choose 10 pt in the Weight menu. Click OK.
  • Click the Change All button. Hopefully, a message reports that three objects have changed.
  • You may close that document, saving it if you’d like. We’ll be assembling something in the next exercise.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset