[fpc-devel] ThousandSeparator

Mark Morgan Lloyd markMLl.fpc-devel at telemetry.co.uk
Thu Nov 27 08:46:52 CET 2014

Sven Barth wrote:
> On 26.11.2014 16:54, Hans-Peter Diettrich wrote:
>> When the system does not notify all other (running) programs of such an
>> global change, or when some other stupid program doesn't know how to
>> deal with changed settings, the user better shuts down and restarts his
>> system, before and after using that ill behaved program.
>> But exactly *what* should a clever program do, when it receives such a
>> change notification? What should happen with the formatted numbers,
>> shown in the forms of the program? Which code (app/OS?) puts the
>> separators into formatted number strings?
> At my old company our Delphi application handled runtime changes to 
> these settings rather well. For display the normal XToY (e.g. DateToStr) 
> functions are used which use the DefaultFormatSettings which are updated 
> automatically (the VCL's message loop triggers a repaint when format 
> settings were changed in the system). *This* is how I expect an 
> application to behave (afterall Microsoft's own applications behave this 
> way as well).

My recollection is that there's a Windows message that indicates that a 
control panel applet has changed localisation etc.  The lack of anything 
comparable on other OSes could be a problem, even if user apps and their 
associated RTLs were happy handling a change.

Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

More information about the fpc-devel mailing list