[fpc-devel] Setting locale format data
mr.ed.123 at gmail.com
Fri Apr 11 02:08:26 CEST 2014
I have an application that reads a locale from a configuration file (simple
form). This determines how the output is formatted, in particular
date-time. This change is local to the application and does not effect the
rest of the computer.
This was originally written in Delphi which provides GetFormatSettings
which is callable after changing the locale. There is also a routine
GetLocaleFormatSettings is neccessary.
Moving this application to FPC, I can still get GetFormatSettings on
The issue is moving this to another platform, in particularly Linux.
I have a routine to deal with the locale namings on the different
platforms, which works nicely. I can change the thread locale. The issue
is that GetFormatSettings is not available.
I have made a local patch to export the equivalent function under linux. I
simply turned the initialization code into a routine and exported this with
the same name.
Can this routine be made available on other/all platforms, or is there a
better way to do it?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the fpc-devel