Copy link to clipboard
Copied
This seems like a fairly common application, but I’ve not found a solution. Hoping the community can provide an answer for me.
Doing a book, and each chapter starts with quotes by notable people. I have a paragraph style for the quote, and a character style for the byline, but need a GREP to apply the character style to the em dash and the name.
Like this:
“notable individual quote.” —BYLINE
In the GREP tab:
Find what:
\x{2014}.+$
This finds the em dash (which is U+2014), followed by anything (.) as many times as possible (+) up to the end of the paragraph ($).
In Find Format, click on the top right corner ("T" with magnifying glass, Specify attributes to find), and choose the paragraph style for the quote.
Leave the Change to field empty.
In Change Format, choose the character style for the byline.
Copy link to clipboard
Copied
Not to diss the wonders of technology and automation, but it seems like you could format 50 such headings in a few minutes — or about as long as it took to write your post. I am always a bit puzzled at designers who want to automate or script simple, one-time tasks. 🙂
—
Copy link to clipboard
Copied
What's odd is you don't know how many I need to format like this and what other numerous, similar items need special formatting where a GREP will save me hours ... now do you?
Please save your comments when you have something helpful. Take your puzzle elsewhere.
Copy link to clipboard
Copied
Hey, I started off pasting bits on blueline board. I have great appreciation for time-saving and efficiency methods. 🙂
—
Copy link to clipboard
Copied
In the GREP tab:
Find what:
\x{2014}.+$
This finds the em dash (which is U+2014), followed by anything (.) as many times as possible (+) up to the end of the paragraph ($).
In Find Format, click on the top right corner ("T" with magnifying glass, Specify attributes to find), and choose the paragraph style for the quote.
Leave the Change to field empty.
In Change Format, choose the character style for the byline.
Copy link to clipboard
Copied
Samuel, this worked perfectly!!
Thank you for the valuable help without any arrogant smuggery. (RE: NitroPress)
Copy link to clipboard
Copied
Glad I could help! The trick is to leave the Change to field empty, so the style you specify in the Change Format will be applied to the found string (from Find what).
Copy link to clipboard
Copied
Why don't use simply nested styles?
Copy link to clipboard
Copied
@jmlevy @Jim's solution is the most efficient and elegant.
Copy link to clipboard
Copied
perhaps, unfortunately, i only understand English.
Copy link to clipboard
Copied
In the nested styles section, set the following:
Find more inspiration, events, and resources on the new Adobe Community
Explore Now