Back

If your email is not recognized and you believe it should be, please contact us.

  • You must be logged in to reply to this topic.Login

Find & Change a character with styles?

Return to Member Forum

  • Author
    Posts
    • #14373152
      Phyllis Utter
      Participant

      Hi! Is there a way to find and replace a character inside a style? Not the style itself, but the actual character? I seem to remember once seeing a trick where someone could type a short word and it would automatically replace it with a longer one (or something like that). Specifically, I have a style where I want any instance of an apostrophe to switch the apostrophe to an alternate glyph for the apostrophe (because the default apostrophe has an oddity to it that I don’t like, but I still need to keep the particular font). Rather than running find-and-replace repeatedly (whenever text is updated, the bad apostrophe comes in), do I remember that there was some other way to force that replacement to happen automatically with styles? Or is that just wishful thinking? I checked out the GREP panel for the style in question, but it looks like I could only apply a style there. Any suggestions? Thanks, Phyllis

    • #14373153
      Petar Petrenko
      Participant

      I think it should work:

      Find what: old apostrophe
      Change to: the new one

      Find Format: the char. style
      Change Format: choose the same one

      • #14373154
        Phyllis Utter
        Participant

        Thanks. I was looking to see if there’s an automated approach though (to prevent doing find-and-replace repeatedly). I have editors constantly updating copy, and that automatically brings in the old apostrophe over and over (and I’m trying to make proofs at various stages of the process without having a bad character inside it). I thought I remembered a technique of somehow building the change in — it was whatever method allowed you to type an abbreviation and have it automatically convert to a name. Maybe that was in different software though!

    • #14373155
      Steve Davis
      Participant
    • #14373167
      Dhafir Photo
      Participant

      You can do it automatically by using GREP Style
      First create character style for the new apostrophe, then copy the old apostrophe and paste it in “To Text” field

    • #14373284
      David Blatner
      Keymaster

      There is an Auto-Correct feature in InDesign… and you can hack it to do special characters:

      Hidden Autoexpand Feature in InDesign


      and

      InDesign How-to Video: Add Special Characters to Autocorrect

    • #14373304
      Phyllis Utter
      Participant

      Hi all!

      Thanks for the input! And my apologies for the slow response — I read everything but couldn’t come back to this for while due to a deadline. And David, yes, that is the article I was remembering!!!

      BUT — it turns out the entire premise behind my question was wrong, hah. I misunderstood something about the Glyphs panel. I thought each glyph that was shown was an entirely different character. I didn’t realize that an alternate character is still the same character. I figured it out because I was doing Find-and-Replace on the apostrophes and kept mixing things up the find and replace fields. It seemed like the exact same find-and-replace would do opposite things. I finally found the apostrophe that looked right to me and selected it and said “new character style.” Here’s the character style I needed:

      I did NOT realize you could call the alternate selection for a character like that!

      And now that I know that, I’ll use a GREP style. :) I’ll base all the styles in this font off a base that includes that. :) I already have that based on a base style (per someone’s helpful class one time). Now I just need an additional base for the styles that use the font that has an ugly apostrophe in it.

      Am I the only one who didn’t know that the alternates for the same character work like this?

      Thanks, Phyllis

    • #14373307
      Phyllis Utter
      Participant

      PS: I’ve tried to create the above style manually in the OpenType Features dialog, but I can never get that exact same style setting that way. I have to pull in the alternate apostrophe from the Glyphs panel and select it first — then build a character style — to get that exact same style.

    • #14373345
      David Blatner
      Keymaster

      Yeah… this may not work with a character style, unfortunately. You may just have to use Find/Change. For example:

      Finding and Changing Glyphs


      or

      Insert a Character by Unicode or GID

      • #14373349
        Phyllis Utter
        Participant

        Hey David, What I’ve said does works :) I made that character style into a GREP style and put it in. When I pick that paragraph style, the apostrophe replaces immediately as I type or when I import type. :) I think it’s the item that says “Glyph Form: Proportional Width Forms” in the screenshot above that’s doing the trick. The alternate apostrophe is a style of the original apostrophe — it just wasn’t easy to figure out how to save it as a style. But the screenshot I’m showing above does work and is replacing the apostrophes everywhere with the alternate. It’s one of the glyphs that appears when you view only “alternates for selection” in the Glyphs panel. I guess those alternates are styles of the original (rather than completely separate characters) if you can get the styles right!

        I’m going to check out your other articles above anyway though, as I’ll have other uses. So thanks!

    • #14373305
      Phyllis Utter
      Participant

      Actually, I might just be able to turn off Contextual Alternates in the style itself because that seems to be what it’s about. I’ll see what that does to other stuff before I do anything wholesale to all the characters though.

Viewing 8 reply threads
  • The forum ‘General InDesign Topics (CLOSED)’ is closed to new topics and replies.
Forum Ads