Arabic/RTL/I18N support

Reversing the characters is a good start. In my quest to find a 2D game engine that supports Arabic text natively, I came across a lot of details (some of which weren’t mentioned here, sorry).

There are several pieces that need to be in place for this to work properly:

  • Unicode support for non-ASCII characters (so you don’t see boxes)
  • Right-to-Left support (Chinese/Japanesse/Korean, Arabic, Urdu, etc.)
  • Glyph shaping. In languages like Arabic, Thai, and others I can’t remember, the letter appears differently depending on if it’s the first, last, or middle letter in the word.

All of the game engines that I’ve found seem to use HarfBuzz to implement this. It’s not a small library, but it handles all of the different languages well. I think it’s some sort of C++ library.

@Pkeod how did you generate your second image (this one)?:

This is how the text is supposed to look.

4 Likes