[Lazarus] Does Lazarus support a complete Unicode Component Library?

Sven Barth pascaldragon at googlemail.com
Wed Feb 16 13:20:37 CET 2011


Am 16.02.2011 11:52, schrieb Hans-Peter Diettrich:
>> I must add, that I would be very surprised if Embarcadero doesn't use
>> native encoded string types for the "unicode string" support in the
>> upcoming Delphi under Windows (UTF-16), Linux (UTF-8), Mac (UTF-8) etc..
>> I'm not 100% sure about the default Mac encoding, but seeing that it
>> comes from FreeBSD, I would guess UTF-8 there too.
>
> AFAIK the UnicodeString allows for any dynamic encoding, be SBCS, MBCS
> or UTF-8/16. The element (char) size and encoding have become part of
> every Unicode string descriptor.

This is wrong.

The following compiles:

type
   UTF8String = type AnsiString(65001);

but the following does not:

type
   UTF8String = type UnicodeString(65001); // ';' expected, but '(' found

Tested using Delphi XE (65001 is the codepage for UTF-8 on Windows).

Regards,
Sven




More information about the Lazarus mailing list