[fpc-devel] Unicode support (yet again)

cobines cobines at gmail.com
Thu Sep 15 10:43:16 CEST 2011


2011/9/15 Michael Schnell <mschnell at lumino.de>:
> In fact users want to deal with "decently coded characters" and not with
> "cryptic bytes some of which together are representing a character". (e.g.
> when doing MyChar := MyString[1]; )

I think of Unicode text as a stream of Unicode characters in some
format. I trust that functions that deal with the string Copy, Length,
Find, etc., know how to handle it.

When doing:
MyChar := MyString[1]

appropriate function retrieves first unicode character, regardless of encoding.

Whether it's utf8, utf16, utf32 or any other future encoding the code
should work the same.

--
cobines



More information about the fpc-devel mailing list