1、1,An ICU Library Supporting the Display of Complex Text,Eric M,Globalization Center of Competency, Cupertino, CA,2,Overview,What is complex text? What is the ICU LayoutEngine? How does it support the display of Indic, Arabic and Thai text?,3,What Is Complex Text?,Unicode: not just a bigger character
2、 set Bidirectionality: mixed directions on a line Shaping: character shapes depend on context Ligatures: mandatory special forms, and no Unicode equivalent Positioning: vertical and horizontal adjustments Reordering: character positions depend on context Split characters: some characters appear in m
3、ore than one position,4,Bidirectional Text,Visual order differs from storage order Arabic and Hebrew read right to left, but numbers still read left to right,memory,reading order,5,Character Shaping,Arabic character shapes change to connect adjacent characters,6,Ligatures,Arabic and Devanagari repre
4、sent some character sequences with ligatures,7,Character Positioning,Thai (and other scripts) require characters to reposition,8,Reordering,Some Hindi characters reorder based on context,9,Split Characters,Thai and many Indic languages display a single character in multiple positions,10,What is the
5、ICU LayoutEngine?,Open source w/ GPL compatible license Written in portable subset of C+,11,What is the ICU LayoutEngine?,Open source w/ GPL compatible license Written in portable subset of C+ Portable, platform independent,12,What is the ICU LayoutEngine?,Open source w/ GPL compatible license Writt
6、en in portable subset of C+ Portable, platform independent Simple, uniform interface,13,Supporting Complex Text,Smart font technologies OpenType Uses GDEF GSUB GPOS tables Processing is script, language specific “up-front” text processing AAT Uses mort table Applies default features Only left to rig
7、ht text No positional processing,14,Supporting Complex Text,Smart font technologies Unicode presentation forms Used for Arabic and Hebrew Only if no OpenType, or AAT tables in font Uses “canned” OpenType tables Generated from Unicode Character Database file Uses code points rather than glyph ids Use
8、s filter to skip missing forms, ligatures,15,Supporting Complex Text,Smart font technologies Unicode presentation forms Special processing for Thai No OpenType specification for Thai State table based processing Uses Microsoft, Apple, IBM encodings,16,LayoutEngine Class Hierarchy,17,Demo,18,Resources,ICU: http:/ OpenType Specifications: http:/ TrueType Font File Specification: http:/