Change style with GREP inside a paragraph style

Community Beginner ,
Jun 09, 2022 Jun 09, 2022

Copy link to clipboard

Copied

Hello to all

I have a bilingual line in my document, something like

Presentation  |  Apresentacao

Inside a paragraph style, I created a GREP to apply a Character style from the "|" character on.

\x{007C}.+$

How could I changed it to apply this character format only AFTER the "|" character? I don't want include the | in the character style.

 

Thanks in advance

Rita

TOPICS
How to

Views

104

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 2 Correct answers

Adobe Community Professional , Jun 09, 2022 Jun 09, 2022

It would be easier to use nested styles.

Capture d’écran 2022-06-09 à 23.51.16.jpg

 

Capture d’écran 2022-06-09 à 23.50.41.jpg

Likes

Translate

Translate
Community Beginner , Jun 09, 2022 Jun 09, 2022

I joined your solution to mine and the following expression worked out:

(?<=\|).+$

Thak you all

Likes

Translate

Translate
Adobe Community Professional ,
Jun 09, 2022 Jun 09, 2022

Copy link to clipboard

Copied

It would be easier to use nested styles.

Capture d’écran 2022-06-09 à 23.51.16.jpg

 

Capture d’écran 2022-06-09 à 23.50.41.jpg

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 09, 2022 Jun 09, 2022

Copy link to clipboard

Copied

I used nested styles elsewhere, but here, sometimes I have 1 word, sometimes uo to 3 before the |

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jun 09, 2022 Jun 09, 2022

Copy link to clipboard

Copied

It does not matter, the trigger to apply the character style is the |, not a number of words.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 12, 2022 Jun 12, 2022

Copy link to clipboard

Copied

ok, I see it now. Thank you so much!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jun 09, 2022 Jun 09, 2022

Copy link to clipboard

Copied

(?<=\|) \w+

This grep will find "1 space" and "word" after "|"

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 09, 2022 Jun 09, 2022

Copy link to clipboard

Copied

I joined your solution to mine and the following expression worked out:

(?<=\|).+$

Thak you all

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jun 10, 2022 Jun 10, 2022

Copy link to clipboard

Copied

(?<=\|).+$

This expression will find everything after "|" up to the end of paragraph.

If your situation is just:

English | Spanish^p

your expression works.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jun 12, 2022 Jun 12, 2022

Copy link to clipboard

Copied

LATEST

Be aware that GREPs make InDesign slower, nested styles are faster.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines