[fpc-pascal] FPC 3 regression: cannot use TStringList for UTF-8 data any more?
juha.manninen62 at gmail.com
Mon Apr 4 12:27:05 CEST 2016
On Mon, Apr 4, 2016 at 12:52 PM, Graeme Geldenhuys
<mailinglists at geldenhuys.co.uk> wrote:
> This is the FPC mailing list. Not everybody here uses Lazarus or LCL, so
> making such a suggestion is wishful thinking. For example, your
> suggestion means nothing to me, I don't use LCL.
Yes, I should have mentioned that this feature does not require LCL.
It only requires LazUtils package and LazUTF8 unit in your uses
It can be used in cmd line and server programs and I guess in fpGUI,
too, although I have not tested.
But yes, it requires Lazarus IDE because LazUtils is a Lazarus
package. At least you must create and compile the project using
Anyway, this UTF-8 mode does more that sets the default String encoding.
It also provides proper UTF-8 functions as backends for RTL's
Ansi...() string functions.
It also uses cwstring although it pulls in clib.
Then typical users' code is amazingly Delphi compatible despite the
different encoding, because code only seldom deals with individual
codepoints beyond 7-bit ASCII.
More information about the fpc-pascal