Skip to main content
Participant
February 21, 2018
Question

Using the same GREP on all paragraph styles

  • February 21, 2018
  • 3 replies
  • 3214 views

I'm a big fan of GREPs, particularly for large documents like annual reports. However I always thought that you could set up GREPs from the Paragraph Palette that would include all text regardless of what paragraph stye you're using, however I'm finding that its a bit hit and miss.

For example, I always want the phrase 'Corporations Act 2001' in italics, whether it is used in body copy, bullet copy or footnotes. So instead of setting up the GREP in each paragraph style, I want it to apply to the document overall.

My new problem is that a client wants to use a particular typeface (Maax) for their annual report but they want to use the alternate font for certain numerals and characters. I thought the best way to do this is to set up a GREP for each of those characters liked to a character style to change it to the alternate.

I thought this might be the most expedient way to do this short of them supplying me a customised typeface family.

Does anyone out there know if there's a better solution?

    This topic has been closed for replies.

    3 replies

    Mike Witherell
    Community Expert
    Community Expert
    February 21, 2018

    You could spend on a Typifi product that makes GREP event activities part of the InDesign document.

    Or simpler, use this script that can send GREP expressions into multiple paragraph styles all at once:

    InDesign: A simple GREP editor | Peter Kahrel

    That way, you don't have to set up Based-On dependencies, which can become complex and confusing (at least to me) and you can keep all styles independent, yet still edit your GREP in one dialog box interface and affect all paragraph styles at once.

    Mike Witherell
    John Mensinger
    Community Expert
    Community Expert
    February 21, 2018

    Well, a GREP style certainly does seem like a good fit for your "new problem."

    One thing to note, if you set up your paragraph styles in a logical order, starting with headings, working down through body, and on to bullets, footnotes, etc., you can make use of the "based on" feature to cause your "lesser" styles to inherit GREP styles from their parents, i.e., a bullet style based on the body style inherits the body style's GREP styles, along with nested styles, line styles, etc.

    And, if you need a GREP-replacement to affect the whole document, just run it through Find/Change rather than relying on styles.

    Barb Binder
    Community Expert
    Community Expert
    February 21, 2018

    Hi Coops:

    I would set up the character style for the numbers first.

    Then move on to defining the body text paragraph tag, with the nested GREP style for the figures. When you create the other body styles like quote, bullet lists, and numbered lists, be sure to base them on the body text tag so that they pick up the nested GREP style from the parent style.

    Headings don't always have numbers, but if they do, repeat the same process for the title, and then base the subtitles, figure titles, table titles off on the title tag so that they too pick up the nested GREP style from the parent style.

    From Apply paragraph and character text styles in Adobe InDesign:

    ~Barb

    ~Barb at Rocky Mountain Training
    Dave Creamer of IDEAS
    Community Expert
    Community Expert
    February 22, 2018

    Using Barb Binder's character style with John Mensinger's based-on suggestion, why not use the GREP style \d+ set to the character style (that, in turn, is set to the desired number font)? The base paragraph style can be set to Maax, but the GREP style will override it for the numbers.

    I can't imagine working without based-on styles. If you are lucky, the styles might still be based on the [Basic Paragraph] style. In that case, add the GREP style for numbers to that and it will cascade down to the other styles.

    David Creamer: Community Expert (ACI and ACE 1995-2023)
    coops_Author
    Participant
    February 22, 2018

    Thank you all for getting back to me with your solutions. I'll be getting the material for the new document shortly and will enjoy putting what you've all suggested in to practice.

    I'm hoping Maax will only be a headline style which will make my job a lot easier using the methods you've described.