Copy GREP styles from one Paragraph Style to another

Learn / Forums / General InDesign Topics / Copy GREP styles from one Paragraph Style to another

Viewing 6 reply threads
  • Author
    Posts
    • #61177
      John Ryan
      Member

      Greetings from Melbourne Australia O enlightened ones!!

      Since I caught up with you guys in Washington, I've been cranking out GREP like it was candyfloss.

      However, I'm stuck with a bit of a problem.

      1: When I define a GREP style as part of a Paragraph style it works fine

      2: When I define another Paragraph style based on the first style, the GREP portion doesn't seem to be inherited as I would have expected.

      So I guess that I'd like to know how I can copy all the GREP styles from one Paragraph Style to another. And I have plenty of 'em!

      If I could find out where the style is stored (I don't mind cracking into some JS or XML files if necessary) I could just copy 'em accross.

      Perhaps there's a script available for this??

      Please help URGENTLY !!!

      In anticipation I wait.

      #61179
      John Ryan
      Member

      OK I found something that looks like it might work:

      https://www.kahrel.plus.com/ind…..ditor.html

      However I noticed that when I tried to copy styles, it wouldn't address styles that were part of a group (folder)

      Anyone else get an answer, please publish.

      Cheers

      JR

    • #61181

      1: When I define a GREP style as part of a Paragraph style it works fine

      2: When I define another Paragraph style based on the first style, the GREP portion doesn't seem to be inherited as I would have expected.

      That's a bit of a quizzler mate. The only way I can get to loose the “Based on” GREP style is by putting any GREP style in the new style before changing the Based On name. I have no trouble at all with my own flock of styles, all based upon a single great-grand-parent style, and I can add, remove, and edit GREP styles all along the way and see the changes propagate downwards.

      It's possible to script it but it would need a cumbersome dialog (copy from what to what paragraph style) — I guess if the normal lines of inheritance don't work properly, it's easier to just copy and paste the expression.

    • #88926
      P R
      Member

      i have the same problem, my child paragraph styles doesn’t inherit the GREP styles defined in the parent paragraph style, any help is greatly appreciated.

    • #88927
      Peter Kahrel
      Participant

      What exactly do you mean by ‘parent paragraph style’? The based-on style or the parentstyle group?

      • #89330
        P R
        Member

        The based-on style

    • #89384
      Tom Tom
      Member
    • #89434
      Wosven S
      Member

      Hello,

      I did a script to copy/paste GREP/nested and lines styles from document to document.
      It store style in a text file.

      There’s a first panel for copying and saving styles.
      A second for styles selection and paste them.

      And you can store styles, and use the text file as a quick memo for copying/pasting usual GREP.

      The script :
      https://raw.githubusercontent.com/Swosven/indesignScripts/master/en_copy_Styles_GREP-Nested-Lines.jsx
      The text file :
      https://raw.githubusercontent.com/Swosven/indesignScripts/master/en_copy_listStyles.txt

      Wos

Viewing 6 reply threads
  • You must be logged in to reply to this topic.
>