2όΠτจࣈΛ্Ґ8bitͱԼҐ8bitʹ۠ͬͯ2ஈ֊Ͱม Format 4 16bitͷҙͷൣғͱάϦϑͷҙͷൣғͷରԠΛ࣋ͭ UnicodeͷBMPͷൣғ͚ͩΛѻ͑Δ Format 6 ࠷େ65536ཁૉͷྻͰ16bitจࣈΛม Format 8 Unicodeͷ্Ґ16bitͱԼҐ16bitͰมදΛ͚ͯ2ஈ֊Ͱม͢Δ Format 10 ࠷େ4294967296ཁૉͷྻͰ32bitจࣈΛม Format 12 32bitͷҙͷൣғͱάϦϑͷҙͷൣғͷରԠΛ࣋ͭ UnicodeͷશͯͷจࣈΛѻ͑Δ Format 13 32bitͷҙͷൣғͱಛఆͷάϦϑͷରԠΛ࣋ͭ UnicodeͷશͯͷจࣈΛѻ͑Δ Format 14 UnicodeͷҟࣈମηϨΫλͰબΕΔจࣈͱάϦϑͷରԠΛ࣋ͭ
2όΠτจࣈΛ্Ґ8bitͱԼҐ8bitʹ۠ͬͯ2ஈ֊Ͱม Format 4 16bitͷҙͷൣғͱάϦϑͷҙͷൣғͷରԠΛ࣋ͭ UnicodeͷBMPͷൣғ͚ͩΛѻ͑Δ Format 6 ࠷େ65536ཁૉͷྻͰ16bitจࣈΛม Format 8 Unicodeͷ্Ґ16bitͱԼҐ16bitͰมදΛ͚ͯ2ஈ֊Ͱม͢Δ Format 10 ࠷େ4294967296ཁૉͷྻͰ32bitจࣈΛม Format 12 32bitͷҙͷൣғͱάϦϑͷҙͷൣғͷରԠΛ࣋ͭ UnicodeͷશͯͷจࣈΛѻ͑Δ Format 13 32bitͷҙͷൣғͱಛఆͷάϦϑͷରԠΛ࣋ͭ UnicodeͷશͯͷจࣈΛѻ͑Δ Format 14 UnicodeͷҟࣈମηϨΫλͰબΕΔจࣈͱάϦϑͷରԠΛ࣋ͭ 16bitͷUnicode͔͠ѻ͑ͳ͍ݹ͍ιϑτΣΞͰϑΥϯτΛ͑ΔΑ͏ʹ ͜ͷܗࣜͷcmapΑ͘ಉࠝ͞Ε͍ͯΔ ΠϚυΩͷϑΥϯτେମ͜ͷܗࣜͷcmapΛؚΜͰ͍Δ
b/ttf2mesh.h @@ -145,8 +145,8 @@ struct ttf_file { int nchars; /* number of the font characters */ int nglyphs; /* number of glyphs (usually less than nchars) */ - uint16_t *chars; /* utf16 codes array with nchars length */ - uint16_t *char2glyph; /* glyph indeces array with nchars length */ + uint32_t *chars; /* utf32 codes array with nchars length */ + uint32_t *char2glyph; /* glyph indeces array with nchars length */ ttf_glyph_t *glyphs; /* array of the font glyphs with nglyphs length */ const char *filename; /* full path and file name of the font */ uint32_t glyf_csum; /* 'glyf' table checksum (used by ttf_list_fonts) */ @@ -455,7 +455,7 @@ int ttf_list_match_id(ttf_t **list, const char *requirements, ...); * @param utf16_char Unicode character * @return Glyph index in glyphs array or -1 */ -int ttf_find_glyph(const ttf_t *ttf, uint16_t utf16_char); +int ttf_find_glyph(const ttf_t *ttf, uint32_t utf32_char); UnicodeͷίʔυϙΠϯτΛ 16bitʹಥͬࠐΜͰ͍ΔॴΛ 32bitʹஔ͖͑ͯ
38 pressed 38 released 39 pressed 39 released 39 pressed 39 released 39 pressed 38 pressed 39 released 38 released 53 pressed 52 pressed 52 released 50 pressed 51 pressed 50 released ͜ͷ൪߸Կ?
W Hello, Wo Hello, Wor Hello, Worl Hello, World Hello, World! Hello, World!a Hello, World! Hello, World Hello, Worl Hello, Wor Hello, Wo Hello, W ʮԿͷจࣈ͕ೖྗ͞Ε͔ͨʯ ͕औΕΔ