Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2009-04

patch for formatfloat when thousandseparator=#0

1 message · 1 person ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Jesus Reyes

Hi, when using clocale unit on serveral linux distros we find that ThousandSeparator=#0 and when using a format like '#,0.00 €' with a number like 1000 it ends with '1'. If thousandseparator=',' it would be formated like '1,000.00 €' it is clear that inserting a #0 in such string when separator is #0 is the problem. Attached is patch to fix it.

Related to this problem is that with clocale unit we can find monetary separator and use it if number separator=#0, this is to make it "more delphi compatible (if one is allowed to call it so)" because under windows number separator is never #0.

It may happen that monetary separator is also #0 but in this case like when the user manually set separator to #0 is handled above.

Jesus Reyes A.

¡Obtén la mejor experiencia en la web! Descarga gratis el nuevo Internet Explorer 8. http://downloads.yahoo.com/ieak8/?l=mx

Reply by email