In Hungarian language (and Windows) defaults we use "decimal-comma", instead of decimal-point to write down float numbers: `100 000,34 (instead of: 100000.34)`
I know, it's not ideal, but that's how it is.
The original ISuperObject had no problem with this, (we have tested!) it has created still numbers `Obj.D['value'] := 100000.34` with dec.point: `{"value":100000.34}`
But now it does insert comma "," instead of point "."
I see at CHANGED: Aug 11, 2020 - V8.65 ... Replaced gcvt with FloattoStr
Usually I am using my own conversion function for these, and thought I could pass the value by string:
var FormatSetting : TFormatSettings;
FormatSSajat : TFormatSettings;
//0x040e Hungarian Hungary 1250 HUN
GetLocaleFormatSettings(1038, FormatSetting);
FormatSSajat := FormatSetting;
FormatSSajat.DecimalSeparator := '.';
FormatSSajat.DateSeparator := '.';
FormatSSajat.ShortDateFormat := 'yyyy.MM.dd'; // Win10 compatibility, because they have changed to 'yyyy. MM. dd' 😮
...
function fts(const i:Double ) : string;
begin
Result := FormatFloat('0.00000000', i, FormatSSajat);
end;
// and pass as string:
json.S['value'] := fts(0.33);
But that is wrong too !!!
because it will enclose it to "" : `{"value":"100000.34"}`
What can we do ?