PDA

View Full Version : Setting locale for the whole app



maverick_pol
16th June 2008, 23:40
Hi guys,

I have problem with strings containing "," rather then "." when storing/reading double values as strings. How to change application QString locale settings to read/write double in string using '.'? I suppose that German locale settings use ',' for storing/reading float in QString, but some other languages use '.'. While using Qt 4.3.4 I had '.', after porting to Qt 4.4.0 (polish settings) I have ','. How to change the settings?

Thanks.

Kacper

Conel
17th June 2008, 16:17
How to change the settings?

http://www.cplusplus.com/reference/clibrary/clocale/setlocale.html

jacek
22nd June 2008, 22:53
See QLocale.