GREP was staring me in the eye

I was sitting here looking at the search string I posted in yesterday’s blog, and realized that the solution to my problem was staring me in the eye.

The string I posted yesterday was for forcing ALL CAPS into lower-case. It was a solution that included not converting Roman Numerals. I don’t really need the Roman Numerals feature, I just need the ability to change normal strings of capitalized text into lower-case, and I don’t want my search string to include articles like A and I. Compound-words, words followed by periods, commas, hyphens, semicolons, and colons also need to be converted.

The secret is in the braces part of the string: {2,} which translates into find at least two capital letters. That solves the problem if I tag it on the end of a search string that searches for the capital letters of the alphabet [A-Z].

The search string that solves my problem is:

This, combined with the Javascript I licensed a couple of weeks back, provides a solution that I like. I can now stop obsessing over this particular GREPping drama.

 

About Brian Lawler

Brian Lawler is an Emeritus Professor of Graphic Communication at California Polytechnic State University, San Luis Obispo and was a Guest Professor at Hochschule München from September, 2021 to September, 2022. He writes about graphic arts processes and technologies for various industry publications, and on his blog, The Blognosticator.
This entry was posted in Imposition and Pagination. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.