Internationalisation

How can I support or display multiple languages?

We currently only support Latin-based languages, however other scripts (such as Cyrillic, Hebrew, Arabic) may still work.

PDF

Fonts

Using the default

As noted in the Design a PDF template guide, when no custom font is specified the default Helvetica font is used. This font uses Windows-1252 encoding character sets which only support 218 characters in the Latin alphabet.

Full character set:

https://www.datocms-assets.com/38428/1655366003-helvetica.png?auto=format

Supported languages:

English, Irish, Italian, Norwegian, Portuguese, Spanish, Swedish, German, Finnish, Icelandic, French, Faroese, Luxembourgish, Albanian, Estonian, Swahili, Tswana, Catalan, Basque, Occitan, Romansh, Dutch (except the IJ/ij character), and Slovene (except the č character)

If your payload contains characters outside of this character set, you must use a custom font that has character support for your languages.

Using a custom font

MATTR VII currently only allows for a 1MB maximum template.zip file. This means CJK (Chinese, Japanese and Korean) fonts would generally be too big. If this affects your implementation, please contact us.

Templates

You may wish to make your PDF bilingual / trilingual / multi-lingual. Unlike apps or websites, PDFs cannot display different languages depending on the user’s system language preferences. We recommend two options to address this:

  • Display all the languages on a single template: Real world example of this is a passport. The labels have multiple languages on it, and often so does the disclaimer and informational text. This approach may be useful if your use case requires cross-regional holder and verifiers, and the verifier may not be familiar with the credential itself.

  • Different template files for different languages: If you are already obtaining the user’s preferred language, you may wish to create multiple templates and switch between them as needed. This is useful if the credential would generally be used within one region or presented remotely.

Apple digital pass

Generally if the language you want to use is available as a system language on iOS, or if there are no issues displaying characters from your language in iOS, then you should not run into any issues.

Apple Pass offers multi-language passes. This means a single pkpass file can include multiple languages. The language that gets displayed to the end user will default to the user’s device system language. To learn more about this see Apple’s Developer Documentation.

Google digital pass

Generally if the language you want to use is available as a system language on Android, or if there are no issues displaying characters from your language in Android, then you should not run into any issues.

Like Apple Pass, Google Pass offers multi-language passes. You would need to use the LocalizedString API type. See Google Wallet API reference for more information.