Localization and Currency

Hi,
what is the best way to manage locales and currencies in Haxe, like AS3 does with the globalization package? I need to handle (easily) different language, currencies and their formatting. I have just read about Fire Tongue, but I don’t know anything about it and especially what are the alternatives to it.

Firetongue might be a good option for localizing text, I’m not sure if it includes anything for currency. If you open Excel (or some other program) and choose the “Currency” format type, you can see different variations in how currency is handled. Some people expect to have commas for large numbers (like 100,000) but others use decimals, which is confusing :wink: (100.000)

Also for different uses, you might do negative numbers differently, like in accounting, you might use parenthesis to denote negative numbers (100,000)

The primary difference, though, is in different symbols for the type of currency

Yes, I know, I past a lot of time in AS3 struggling with currencies :wink:
I could restore the infos about separators in the currencies xml I used in AS3, but if there is a library that handles it automatically I could go faster, I think it is not necessary to reinvent the wheel ;).

Yes, you have the thx libraries http://thx-lib.org/ The culture one is what you are looking for http://thx-lib.org/lib/thx.culture/

1 Like

Very interesting! Thank you!
I am going to have a look at thx.culture and thx.format.