[Lazarus] Any chance of changing the LCL Unicode encoding to UTF-16?
Graeme Geldenhuys
graemeg.lists at gmail.com
Mon Aug 4 11:02:49 CEST 2008
2008/8/4 Ivan Gan <ivan at comchatter.com>:
> UTF-8 is the better encoding system to use
> It is more compact than UTF-16 & why make applications more bloated than
> they already are?
Unfortunately the argument isn't that easy! There are many compelling
reasons to implement utf-8 or utf-16. It's not a black & white
argument.
And please don't read this as I'm against utf-8. On the contrary, I
implemented UTF-8 as our internal encoding in fpGUI as well.
> Lazarus is now in my view a better environment to work with & is beginning
> to take the lead anyhow
The Free Pascal Compiler can be placed in the same context. For my
line of work, I must agree with our statement. ;-)
> We have effective Unicode support in Lazarus, ok, next problem please, thats
> my view
Again a narrow point of view... It may work fine if you only write
English applications. A simple example where FPC (and Lazarus) is
failing with unicode support (and no easy solution is available), is
in locale information.
For example:
The ThousandSeparater variable is a Char type (1 byte type), yet the
Russian character for a thousand separater (U+00A0 character) requires
2 bytes (the utf-8 encoding would be $C2 $A0).
There are a few other such cases with locale information alone. Simply
changing the ThousandSeparater type or other locale types is also not
an option, because the gets used in many SysUtils functions like
FormatDateTime(), FormatFloat() etc...
Regards,
- Graeme -
_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
More information about the Lazarus
mailing list