Skip to main content
charlieg19576563
Inspiring
July 7, 2023
Answered

Apply style GREP

  • July 7, 2023
  • 7 replies
  • 636 views

Lorem ipsum. This text should have character style applied : loreim ipsum. Lorem ipsum.

 

Hello!

How do i apply positive look behind for the following above? 

from "." "space" all the way to ":"

 

Thanks 🙂

This topic is closed to new replies. Start a new post to keep the conversation going.
Correct answer charlieg19576563

Hi @charlieg19576563 

Try these 2 queries. Not the more elegant way to achieve what you want, but it works.


You guys are the best! All of you involved 

7 replies

m1b
Community Expert
Community Expert
July 7, 2023

You might get away with just using Nested Styles in the Paragraph Style. Like this:

But if you really want a grep, then something like:

(?<=\. )[^:]+(?=:)

 - Mark

charlieg19576563
Inspiring
July 7, 2023

Almost there!
"." everything between ":" only

jmlevy
Community Expert
Community Expert
July 7, 2023

Hi @charlieg19576563 

Try these 2 queries. Not the more elegant way to achieve what you want, but it works.

Derek Cross
Community Expert
Community Expert
July 7, 2023

What you're looking for is not clear (at least to me!). What do you mean by "applying a positive look" to a Character Style?

charlieg19576563
Inspiring
July 7, 2023

Good day sir,
I want to apply a style I've setup to:
everything between the "." to the ":"