GREP: find only the quoted words within parenthesis

Learn / Forums / General InDesign Topics / GREP: find only the quoted words within parenthesis

Tagged: 

Viewing 1 reply thread
  • Author
    Posts
    • #79510
      Jahrod
      Member

      I am trying desperately to make a GREP style to words within parenthesis that might have double quotation marks (I want the quotation marks and the words changed to a style, but no other words within the parenthesis). Example:

      (my white “dog”)
      (“cat”)
      (“dog and cat”)

      The problem I have is I cannot figure out how to find “dog” in my first example, although I can find “cat” and “dog and cat” just perfectly.

      Here’s my GREP so far:

      (?<=\()”.+?”(?=\))

      Can anybody please help me adjust the above GREP so that it also finds “dog” in my first example?

      Many thanks!

    • #79574
      Jahrod
      Member

      For those who may be interested, the GREP code for what I needed is:

      \([^“\)]*\K“[^“]+”

      Message thread for that solution: https://forums.adobe.com/message/8205528#8205528

Viewing 1 reply thread
  • You must be logged in to reply to this topic.
>