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

Graeme Geldenhuys graemeg.lists at gmail.com
Tue Feb 15 07:50:49 CET 2011


Op 2011-02-14 20:03, Jürgen Hestermann het geskryf:
> Do you mean that the compiler should convert the strings as needed in
> the background (as between different integer types and/or floats) so
> that you can call ListBox1.Items.Add(x) with x beeing UTF8string or
> UTF16string or...?

Yes, but in reality how often would such conversions happen? TStringList
(used inside a TListBox) would use UnicodeString types. The encoding of
that type would default to whatever platform you compiled on. ie: under
Linux it would default to UTF-8, and under Windows it would default to
UTF-16

So if you define a new string of UnicodeString type in code, it would
automatically match the encoding type of the TStringList, so when you
add a string item to the listbox, no conversion would be needed. This
would probably be the case 99% of the time.

The developer would physically have to create a new string with and
manually set an encoding different to the platform default, before a
auto-conversion would be required.

In day-to-day work and in most cases auto-conversions will be kept to a
minimum - automatically.


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/





More information about the Lazarus mailing list