[fpc-devel] bug report 20473: Please add a directive to define string=utf8string
Paul Ishenin
ip at kmiac.ru
Thu Oct 13 09:44:58 CEST 2011
13.10.2011 15:29, Felipe Monteiro de Carvalho пишет:
> Hello,
>
> Posting here as this was requested in the bug report:
> http://bugs.freepascal.org/view.php?id=20473
>
> I think it is very simple: Having such a directive would save a lot of
> work when porting Lazarus-based projects to FPC 2.7
>
Wrote to that issue and writing here.
When String = AnsiString you only need the way to set codepage of
ansistring constants to UTF8 and default codepage for conversions.
The first can be made either by {$codepage UTF8} directive or by -FcUTF8
directive.
The later can be made by call SetMultiByteConversionCodePage(CP_UTF8) at
the program start.
Best regards,
Paul Ishenin.
More information about the fpc-devel
mailing list