From: "Iñaki Baz Castillo" Date: 2009-08-02T23:49:28+09:00 Subject: Re: qtruby overrides "to_s" depending on user's LOCALES El Domingo, 2 de Agosto de 2009, Stefano Crocco escribió: > Regarding your question, you can find an explaination of why this happens > (and some workarounds) in this thread of the qtruby forum: > http://rubyforge.org/forum/message.php?msg_id=67059 Yes, after sending the mail I found the same thread :) > If you only want a quick solution, you can do the following: create a > Qt::Locale object based on the C locale using Qt::Locale.c, sets its > number_options property to Qt::Locale::OmitGroupSeparator and use its > to_string method to create the string. Something like this: > > x = 1234.567 > l = Qt::Locale.c > l.number_options = Qt::Locale::OmitGroupSeparator > puts l.to_string(x) But this is not valid to me since I use 3rd party libraries (as httpclient which suffers this issue when generating a HTTP request). Then, I assume that I must change the locales globally but this would break the Qt translations and so... :( Dark issue... Thanks a lot. -- Iñaki Baz Castillo