GREP doesn't just describe text characters in the abstract.…It can also describe a specific location within text, allowing you to specify in…a GREP pattern where something is, not just what it is.…The thing to remember about locations, however, is that they really can't be seen.…If a location such as the beginning of a paragraph is being described in GREP,…it's not referring to the first character at the beginning of a paragraph.…It's referring to the space that your cursor occupies when it's placed at the…beginning of a paragraph, as such, highlighting something like this in a GREP…Style is not really going to show you anything on the screen.…
For example, with my cursor in the body copy text in this file, and I am…zoomed in again on page 2 of this layout to better see the text, if I…right-click on the Body Text style name in the Paragraph Styles panel, choose…Edit Body Text, go to GREP Style.…I am going to create a New GREP Style here and from the Apply Style menu, I'm…going to choose the Yellow Highlight character style.…
Author
Released
11/18/2009- Using metacharacters, the building blocks of GREP
- Describing text that may not exist with zero operators
- Applying multiple character styles to the same text with GREP styles
- Eliminating orphaned words at the ends of paragraphs
- Preserving and recalling subexpressions
- Customizing a GREP-based text cleanup script for long documents
Skill Level Intermediate
Duration
Views
Q: In the “Dynamically fixing orphaned words with GREP” tutorial the author uses the term:
(?<=\w)\s(?=\w+[[:punct:]]+$)
In an earlier course the author described the + (one or more) modifier as unusable in a lookbehind or lookahead i.e. (?<=.+). What's the difference here?
A: The limitation mentioned in an earlier movie referred only to positive lookbehind and negative lookbehind. I was able to use the one or more times (+) metacharacter in the positive lookahead portion of the expression because that limitation doesn't affect either positive or negative lookahead. It's only when looking backward that GREP ignores the repeat metacharacters.
Related Courses
-
InDesign Secrets
with David Blatner38h 45m Intermediate -
Learning Regular Expressions (2011)
with Kevin Skoglund5h 36m Intermediate
-
Introduction
-
Welcome1m 4s
-
-
1. GREP Basics
-
What is GREP?1m 53s
-
-
2. Basic Metacharacters
-
Escaping out metacharacters2m 49s
-
Building with wild cards9m 9s
-
Specifying locations7m 4s
-
3. Advanced Metacharacters
-
Creating "or" conditions5m 24s
-
Building subexpressions5m 52s
-
-
4. GREP Styles
-
Describing inconsistent text6m 59s
-
5. GREP Find/Change
-
Understanding queries8m 19s
-
Cleaning up text with GREP2m 45s
-
6. A Practical Project with Advanced Find/Change and GREP
-
Conclusion
-
Goodbye27s
-
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.
CancelTake notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.
Share this video
Embed this video
Video: Specifying locations