Quick Tip: How to Batch Replace Characters and Glyphs


Whether you live in a non-english speaking country, or find yourself editing text for clients in other languages, you're very likely to need a quick way to add glyphs and diacritics to words in InDesign. In the following Quick Tip you will learn how.


Suppose you receive a text document from your client which is in French, and you need to turn it into a creative design. But how about those è's, à's and the € signs? There are of course dictionaries in InDesign that do a good job spell checking and correcting words in all major languages, but what can be done when the text is in, say, Polish, or Romanian? We'll there's a more obscure tool you can use – that is InDesign's "Find Change by List" script. What this does it set up a custom dictionary as a plain text list of replace rules, using Unicode to define those characters that need to be automatically replaced. I've been using this feature quite a lot recently and I recommend you give it a try too.

Step 1

Place, or simply paste your text from the original source (usually MS Word) into InDesign. Depending on the font you are using and the patience your client had in writing the original content, all the diacritics should be in place. If that's the case, then you're done, otherwise skip to the next step.

Step 2

Open the Window > Utilities > Scripts panel and locate the "FindChangebyList.jsx" script under Samples > VBScript. Right click on it and choose "Reveal in finder" so that you find out where the source text file is located. We will be editing this text file to add replace rules that will be run by the script.

Step 3

Load the "FindChangeList.txt" file in your text editor. You will see it already has some instructions left in by the author on how to compose your rules, and a few examples which you can easily adapt to your needs.

Step 4

Add your own text or grep rules using the format described in the text file:

text {findWhat:"août"} {changeTo:"ao< U+00FB >t"} {}

Please refer to an Unicode chart table to find out the exact code you need for each glyph.

Step 5

Save the text file. Go back to InDesign, right click the script and choose "Run script". If you have a text box selected, you will get asked whether you need to run the script on the selected text box or the entire document. If nothing is selected then the script will just run on the whole document.

Step 6

Backup your text file, so you can re-use the same rules even if you re-install your system. This is especially handy for large files, the more rules you have in the dictionary, the more you'll want to save your work for future projects. I keep different versions of this text file adapted for a number of clients, and just use the appropriate source rules depending on my project.


Obviously no system is perfect and it takes a while to build an useful list, some people just need a couple of rules, while others need hundreds. However, once you've built your list, you just click to run the script and glyphs start popping up like magic! I hope you enjoyed this Quick Tip.

Related Posts
  • Design & Illustration
    Tools & Tips
    Give Your Design Extra Style With Alternate CharactersAlternate characters
    Do you know that many fonts have alternate characters such as logotypes and swashes? Take advantage of these hidden gems and elevate your design from boom to kaboom! Read More…
  • Computer Skills
    Getting Started with Pages for iCloudPages icloud icon
    Apple's Pages for iCloud web app is a full-featured word processor that works much like its desktop counterpart. In this tutorial, you'll learn how to use all of Pages' online features and how to use it to craft beautiful documents.Read More…
  • Web Design
    Getting the Hang of Hanging PunctuationGrand motel text effect
    Hanging Punctuation is a powerful typographic tool for creating optically aligned bodies of text. Unfortunately, it has been largely forgotten on the web... until now. We’ll take a look at the value of hanging punctuation and how you can partially implement it using a little JavaScript and a CSS rule which has been around for years.Read More…
  • Computer Skills
    App Training
    Alfred Workflows for IntermediatesAlfred400
    Welcome back! Since you are reading this, you must have enjoyed the beginner's tutorial. Great! Now, let’s dig a little deeper by making a workflow that will help manage our Downloads folder, as well as a Projects Manager.Read More…
  • Web Design
    Unicode: A Beginner's PrimerUnicode retina 400x400
    Believe it or not, there's an image format which is built right into your browser. It allows images to be downloaded even before you need them, renders them perfectly on Retina screens, and allows them to have CSS colours and effects applied to them. Ok, I'm not being entirely truthful there. It's not an image format as such – but the rest still applies. Using Unicode you can create icons that are resolution independent, have virtually no download time and can also be styled with CSS.Read More…
  • Web Design
    Start Using Quotation Marks the “Correct” WayQ retina
    Quotation marks, speech marks, inverted commas; whatever you call these forms of punctuation, you might well be using them incorrectly. Let’s take a quick look at what’s correct, what isn’t, and what you can do within your CSS to make sure your quotes are properly formatted.Read More…