Scripts with
complex text layout have contextual and non-linear requirements to render their typography correctly. These requirements include:
ligatures, where two consecutive characters are combined into one shape (Latin, Devanagari); reordering, where some characters are written before the letter they follow in pronunciation (Bengali, Sinhala, and other Indic scripts); and context-shaping, where some letters have to change shape depending on whether they occur in the beginning, middle, or the end of the word (Arabic, Mongolian). Uniscribe uses several script-specific shaping engines for handling typography in supported complex scripts; these are implemented in addition to a generic engine for non-complex scripts (such as Latin or Cyrillic). The currently used engines include Indic (Bengali, Devanagari, Gujarati, Gurmukhi, Kannada, etc.), Arabic, Hangul, Hebrew, Khmer, Myanmar, and Thai/Lao variants. The complexity of the Unicode standard and ambiguities in OpenType specification often result in incomplete or erroneous implementations of complex text layout. Script-specific shaping engines work on a case-by-case basis and do not consistently handle common features of OpenType fonts, which makes it difficult for OS programmers and font developers to support new scripts. Implementation errors are very hard or impossible to correct at a later stage without breaking up
backward compatibility for existing documents and fonts, often requiring new OpenType layout features and a redesign of existing fonts and typography rendering engines. In Windows 10, major refactoring work was done for Uniscribe to implement a generalized shaping model, the Universal Shaping Engine (USE). This engine is directly based on glyph properties defined in the Unicode standard, in the hope that any complex script with a suitable font would be supported without the time and effort required to create a dedicated shaping engine. USE builds on a generalized "universal cluster model" developed for the Indic scripts, which models a superset of human writing systems. The engine classifies each character of a complex script into several categories, base classes and subclasses. For example, a provisional Indic classification includes general, syllabic and positional categories, further divided into base (number, consonant, tone letter, dependent vowel, etc.), base vowel (independent vowel), number (Brahmi joining number), final, medial, and modifier consonants, medial consonants, as well as top, bottom, left and right consonants and vowels. Unicode symbol strings are converted into collections of USE classes using well-defined rules, making glyph composition a standard procedure and allowing inter-character interactions not possible with current language features defined in OpenType specifications. The Universal Shaping Engine was presented at the OpenType Developer Meeting in 2014; a compatible approach was also implemented by the open source
HarfBuzz text shaper. As of 2020, the USE in Windows 10 handles a total of 70 complex scripts: Adlam, Ahom, Balinese, Batak, Bhaiksuki, Brahmi, Buginese, Buhid, Chakma, Cham, Chorasmian, Dives Akuru, Duployan, Egyptian Hieroglyphs, Elymaic, Grantha, Gunjala Gondi, Hanifi Rohingya, Hanunoo, Javanese, Kaithi, Kayah Li, Kharoshthi, Khitan Small Script, Khojki, Khudawadi, Lepcha, Limbu, Mahajani, Makasar, Mandaic, Manichaean, Marchen, Masaram Gondi, Medefaidrin, Meitei Mayek, Miao, Modi, Mongolian, Multani, Nandinagari, Newa, N’Ko, Nyiakeng Puachue Hmong, Pahawh Hmong, Phags-pa, Psalter Pahlavi, Rejang, Saurashtra, Sharada, Siddham, Sinhala, Sogdian, Old Sogdian, Soyombo, Sundanese, Syloti Nagri, Tagalog, Tagbanwa, Tai Le, Tai Tham (limited support), Tai Viet, Takri, Tibetan, Tifinagh, Tirhuta, Wancho, Yezidi, and Zanabazar Square. ==Versions==