[Development] New feature to qstring | QString::toBool()

Thiago Macieira thiago at kde.org
Thu Oct 27 22:19:51 CEST 2011

On Thursday, 27 de October de 2011 21:25:28 Andre Somers wrote:
> QString("1,234").toDouble() also isn't all that clear either, only the 
> QLocale version of those is localized.
> With a US locale, that would result in 1234.0 (more than a thousand), 
> while in the Netherlands, it would be 1.234 (one and a bit).

Right: that needs to be fixed: QString should operate ONLY on the C locale. If 
you need anything with other locales, it should be clearly marked (like "%L1" 
in arg()) or you should use QLocale.

The same goes for QDate and QTime. Does anyone volunteer to do this change?

> If QString::toBool is introduced, there needs to be a properly 
> localized or at least localizable version in QLocale as well, I think.
> André
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
   Software Architect - Intel Open Source Technology Center
      PGP/GPG: 0x6EF45358; fingerprint:
      E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20111027/72a7d50b/attachment.sig>

More information about the Development mailing list