4

I have to regularly type the word H2 into documents for my job. I always forget to make the 2 subscript

I've been watching David Blatner's Indesign secrets and I figured I could use either, commonly misspelled word or to create a GREP Style.

I tried \d., this works but, when I now type any number on its own it will be formatted to subscript.

Is there a way to only apply the formatting to the letters "H2" for it to read H₂?

6

Apply the character style (subscript) to any number 2 preceded by ?< an uppercase character \u

(?<=\u)2

or, apply the character style (subscript) to any number 2 preceded by ?< an uppercase H

(?<=H)2
  • I'm trying to figure out how to change this so that is doesn't change the 2 when its part of a specific word. "H2Van" Can't seem to figure it out. I've tried positive look behind and Match Character Set. I'm not sure what I can do. Any help? – Aasim Azam May 22 at 17:54
  • 1
    This is another question, you can refer to this one when you make a new. – Danielillo May 22 at 18:00
  • I have managed to figure it out. But it's not perfect will ask later. Will do the job just now. – Aasim Azam May 22 at 18:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.