Unicode text

Normal 8-bit ASCII strings can only represent 256 different characters - not enough for logographic or syllabic alphabets such as Chinese Han, Japanese Kana, or Egypt Hieroglyphs. For overcoming the 256-character limit, the Unicode standard was defined with 16-bit strings, representing 65536 different characters. The latest version of Unicode consists of a repertoire of even more than 107,000 characters using different font sets, and supports bidirectional reading order for the correct display of right-to-left writing systems such as Arabic or Hebrew. From version A7.84 on, the engine supports TEXT objects both with ASCII strings and with Unicode TTF strings.

Generating Unicode text

أشهد أن لا إله إلاَّ الله و أشهد أن محمد رسول الله

Οὐκ ἔστιν θεὸς εἰ μὴ ὁ θεὸς μόνος· Μααμὲτ ἀπόστολος θεοῦ



// display a unicode text
function main() 
TEXT* textUnicode = txt_create(10,0);
textUnicode.font = font_create("Arial Unicode MS#30");
txt_loadw(textUnicode,"Unicode.txt"); set(textUnicode,SHOW);

See also:

txt_loadw, file_str_readtow, str_createw

► latest version online