Copy link to clipboard
Copied
Hello!
My name is Dumitru.
I work on design on books, and thus trying for a while to compose a GREP for subtitles to ease mai work load, but no success.
I have the Paragraph Styles and I can do the Character Styles for these subtitles with no dot “.“ at the end of them, of course.
I believe all my best was: ^[\(\u+\l+\d]\.\)+r but it did not work. At least I figured I need one GREP for each subtitle, because my subtitles are all different!
Examples of what subtitles I need is this:
subtitle: I. subtitle
Body text.... body text...body text.
subtitle: A. new subtitle
Body text.... body text...body text.
subtitle: 1. new subtitle
Body text.... body text...body text.
subtitle: a. new subtitle
Body text.... body text...body text.
subtitle: 1) new subtitle
Body text.... body text...body text.
subtitle: a) new subtitle
Body text.... body text...body text.
subtitle: (1) new subtitle
Body text.... body text...body text.
subtitle: (a) new subtitle
Body text.... body text...body text.
I felt I am close but I just could not make it. So, I said I will ask people who really know this otherwise wonderful function of InDesign, GREP.
Thank you.
Copy link to clipboard
Copied
If I understand your setup, you could do this with Paragraph Styles, each having the next set up as Next Style.
You can then select the whole thing, right-click on the Style that comes first, and choose Apply {style} then Next Style.
As long as your paragraphs follow a predictable pattern, you can style the whole thing at once.
Copy link to clipboard
Copied
Dumitru,
What you seem to need is Grep find/replace to apply para styles to paras with no period at their end and a specific numbering at their beginning.
If right, I suggest you to play with auto-numering para styles!
If manual numbering, here're find requests:
Find: ^[A-Z]\.\h.+[^.]$
Replace by format: A._ParaStyle
Warning: maybe interferences with next one!
Find: ^[IVX]+\.\h.+[^.]$
Replace by format: I._ParaStyle
Find: ^\d+\.\h.+[^.]$
Replace by format: 1._ParaStyle
Find: ^[a-z]+\.\h.+[^.]$
Replace by format: a._ParaStyle
Find: ^\d+\)\h.+[^.]$
Replace by format: 1)_ParaStyle
Find: ^[a-z]+\)\h.+[^.]$
Replace by format: a)_ParaStyle
Find: ^\(\d+\)\h.+[^.]$
Replace by format: (1)_ParaStyle
Find: ^\([a-z]+\)\h.+[^.]$
Replace by format: (a)_ParaStyle
To avoid real styling problems (and if right!), I'ld use conditions too [see later!]
(^/)
Find more inspiration, events, and resources on the new Adobe Community
Explore Now