How to Add Localized Forms in FontForge
This guide explains how to implement the OpenType Localized Forms
(locl) feature in FontForge. You will learn how to prepare
language-specific glyph variants, configure the proper substitution
lookups in the Font Info panel, and assign the appropriate script and
language tags to ensure your font renders correct regional characters
automatically.
1. Create the Localized Glyph Variants
Before configuring the OpenType feature, you must create the alternative glyphs needed for specific languages (such as Romanian comma-accent characters or Turkish dotless i forms).
- Open your font project in FontForge.
- Select an empty slot in the font grid or go to Encoding > Add Encoding Slots.
- Create the alternate glyph. For clarity and OpenType conventions,
assign a descriptive name such as
scedilla.loclROUori.loclTRK. - Right-click the new slot, select Glyph Info, and update the Glyph Name.
2. Open the Lookups Panel
OpenType features in FontForge are managed through the Lookups interface.
- Go to the top menu and select Element >
Font Info (or press
Ctrl + Shift + F/Cmd + Shift + F). - In the left sidebar, click on Lookups.
- At the top of the Lookups window, select the GSUB (Glyph Substitution) tab.
3. Add a Single Substitution Lookup
The localized form feature typically relies on a 1-to-1 glyph replacement.
- Click the Add Lookup button.
- Set the Type dropdown to Single Substitution.
- In the feature table, choose or type
loclLocalized Forms. - In the Script and Language list below, click New.
- Select the relevant Script (e.g.,
latnfor Latin). - Select the target Language (e.g.,
ROMfor Romanian,MOLfor Moldavian, orTRKfor Turkish). - Click OK to save the lookup settings.
4. Create the Subtable and Map the Glyphs
Once the lookup is established, you must populate the subtable with the specific glyph mappings.
- Select the newly created
locllookup in the list and click Add Subtable. - Accept the default subtable name or give it a custom name, then click OK.
- In the mapping window that appears, you will define the base glyph
and its replacement:
- Under Base Glyph Name, enter the standard character
(e.g.,
scedilla). - Under Replacement Glyph Name, enter the name of
your localized alternate (e.g.,
scedilla.loclROU).
- Under Base Glyph Name, enter the standard character
(e.g.,
- Repeat this for all glyphs that require alternate forms for the selected language.
- Click OK to close the subtable dialog, then click OK in the Font Info window to apply your changes.
5. Generate and Test the Font
- Go to File > Generate Fonts... to export the font as an OpenType font (OTF or TTF).
- Test the output in software that supports OpenType language tagging
(such as Adobe InDesign, web browsers using the CSS
langattribute, or HarfBuzz-based tools) to verify that the alternate glyph triggers when the corresponding language is applied.