My dear wife is producing a book for a local author. He has typed his own manuscript in Microsoft Word, and it’s going to be about 300 pages.
The author has a habit of substituting the letter l (el) for the numeral 1, and is not entirely consistent about it.
In this example, the letter l is used instead of the numeral 1. It’s pretty obvious here, but in a 300-page manuscript it’s harder to find. Using GREP, one can fix all of the possible conditions where this might happen.
I remember my typing classes in the early 1960s on clunky mechanical typewriters. Back then the numeral 1 wasn’t even on the keyboard. Using the l key instead was the only way to do it.
So, as he types he occasionally types l950, or l970s, or 196l, or some combination of those uses of the letter instead of the number.
This evening my wife and I spent a few minutes to fix all of the errors in the book using InDesign’s implementation of GREP. It involves just two search strings, and it zooms through the entire manuscript in about one second each, repairing the els, replacing them with ones.
There are only two possibilities of l’s showing up in numbers in his text:
l followed by a numeral (as in l9… or l8…)
a numeral followed by l, (as in …6l or …8l)
And, to fix them, one uses the Find and Replace function in InDesign. Choosing the GREP tab, let’s find the first examples, those of l followed by a numeral. Following is the GREP search string for letter l followed by any digit:
And, this is the GREP search for the opposite situation, any digit followed by the letter l:
It’s smart when searching with GREP to use the Find button, then the Find/Change for subsequent searches rather than the Change All button. This, in case you have made an error in entering the GREP command. It prevents new errors from being inserted into the manuscript. Once it looks like it’s working correctly, it will be safe to click on Change All.
Once that set of searches is complete, reverse the commands to search for the other pattern, and do it again. The whole process takes less time than it took me to write this blog entry.
And, it’s fun!
(We geeks love GREP)