O'Reilly logo

GREP in InDesign CS3 by Peter Kahrel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Basics

Before turning to GREP expressions, it may be useful to outline the interface, which is shown in the screenshot in Figure 2. GREP's dialog is similar to the Text dialog, and virtually everything said here about GREP's dialog also holds for the Text dialog. (Indeed, the dialogs are so similar that more than once you will utter #+*?$ before trying to match it using the GREP dialog. Be prepared.) The GREP dialog has several components, marked A to G in Figure 2. We'll deal with them in turn.

The GREP tab of the Find/Change dialog box

Figure 2. The GREP tab of the Find/Change dialog box

  1. Everything you enter in the dialog (the "query") can be saved to disk for future use: search and replace strings, whether or not footnotes should be included, formatting settings—all these things are stored and reinstated when a saved query is retrieved later. To save a query, press and enter a name.

  2. Here you enter what you want to search for. This field accepts text, including GREP codes, though these can also be entered using a menu. Press to access it. The menu is shown in Figure 2. For the purposes of GREP, the last two sections in the menu are relevant (from Wildcards to Posix), and we'll deal with them extensively in this Short Cut. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required