"Hi Tobias,
Strings in Squeak are either ByteString or WideString based on the Unicode codePoints of their characters. Strings are instances of ByteString if they contain characters with codePoint < 256. And instances of WideString if they contain characters with codePoint >= 256. "
| tmpString1 tmpString2 tmpString3 tmpString4 tmpString5 tmpString6 |
$A codePoint = 65.
tmpString1 := String with: $A. tmpString1 class = ByteString. tmpString1 size = 1.
tmpString2 := String with: (Character codePoint: 269). tmpString2 class = WideString. tmpString2 size = 1.
tmpString3 := tmpString1, tmpString2. tmpString3 class = WideString. tmpString3 size = 2.
tmpString4 := tmpString3 copyFrom: 1 to: 1. tmpString4 class = ByteString. tmpString4 size = 1.
tmpString5 := tmpString2 squeakToUtf8. tmpString5 class = ByteString. tmpString5 size = 2.
tmpString6 := tmpString5 utf8ToSqueak. tmpString6 class = WideString. tmpString6 size = 1.
"The national characters mentioned have Unicode codePoint >= 256.
When importing a Unicode font, the guard i < 256 ifTrue: [] in TTFontReader>>#decodeCmapFmtTable: discards all characters with Unicode codePoint >= 256.
This is undesirable as all those characters mentioned have codePoint >= 256.
The guard value > 65535 ifFalse: [ ] in TTCFontReader>>#processCharMap: discards all characters with Unicode codePoint > 65535.
This is required as glyphs size = 65536 .
Most languages have characters with codePoint <= 65535 so this should not be a problem.
Best Regards, Milan "
-- View this message in context: http://forum.world.st/TTF-import-broken-in-5-0-tp4884157p4890434.html Sent from the Squeak - Dev mailing list archive at Nabble.com.