Skip to main content
irphan
Known Participant
December 26, 2021
Question

GREP and Equations Help

  • December 26, 2021
  • 1 reply
  • 218 views

I have many equations to format. I created a stylesheet for numbering system.

Font is Times New Roman | Regular | 12pt.

Condition: All equations will have italic letter but normal superscripts and numbers.

How can I achieve this? I want to use GREP Style attached to Paragraph Style.


How is this possible?

 

 

This topic has been closed for replies.

1 reply

Peter Kahrel
Community Expert
Community Expert
December 26, 2021

Since in a GREP style you can look for text only, not for any formatting (such as -Superscript), you can't use a GREP style. You'll have to use a GREP query from the Find/Change window.

irphan
irphanAuthor
Known Participant
December 26, 2021

\<[\u\l]{1,2}(?=\h?[\d[:sm:]])|[\d[:sm:]]\h?\K[\u\l]{1,2}\>

I am using this right now but there is one issue. This is also applying on two letters.'is'

Let the superscript apart. Can we use xyz, abc or pqr alone?

Image is attached. 

 

Willi Adelberger
Community Expert
Community Expert
December 27, 2021

Use the positive look behind if only numbers are found before that the italic character style is applied.