[Interest] Missing leading zero in exponential format

Marcel Stegehuis MStegehuis at medis.nl
Wed Mar 15 14:05:38 CET 2017


Since the upgrade from QT 5.3.1 to 5.7.0 it seems that the string output of the exponential format is missing the leading zero:

Using the code below:
double testValue = 1234.5678;
QString (" <Value>%1</value>\n").arg (testValue, 0, 'E', 2);

I expect:
<Value>1.23E+03</value>
but get:
<Value>1.23E+3</value>

Has anyone a clue if this is intentional behavior or how this could be solved?

(See also QT forum: https://forum.qt.io/topic/77226)

Regards,

Marcel


Marcel Stegehuis, ing.
Application Architect

Medis medical imaging systems bv
Schuttersveld 9, 2316 XG, Leiden, The Netherlands
Tel.: 0031715223244 | Fax: +31 (0)71 521 56 17
Email: MStegehuis at medis.nl | www.medis.nl
[medis logo]<http://www.medis.nl>            [Medis LinkedIn] <https://www.linkedin.com/company/medis-medical-imaging-systems-bv/>   [Medis YouTube] <https://www.youtube.com/medisnl/playlists>   [Medis Google plus] <https://plus.google.com/+MedisNl/>   [Medis Twitter] <https://twitter.com/MedisNL>


Medis Academy<https://medis.nl/Academy> - Check our site for available dates.
Medis Inc Webinar - QMap RE<https://goo.gl/wWyUbL> - March 14th, 2017 @ 09:30AM (GMT-5)
Medis Inc Webinar - QStrain RE<https://goo.gl/Vww0uv> - March 14th, 2017 @ 10:30AM (GMT-5)

ACC 2017<https://accscientificsession.acc.org/>, Washington DC, USA, Booth 2725, 17-19 March
BSCMR 2017<https://www.bscmr.org/event/12th-bscmr-annual-meeting-2017/>, Manchester, UK, 28-29 March
CIT 2017<http://www.citmd.com/CIT/2017/>, Beijing, China, 30 March-2 April


Chamber of commerce: 28075744 , VAT: NL806245323B01

***CONFIDENTIALITY NOTICE*** This e-mail is the property of Medis medical imaging systems bv and/or its relevant affiliates and may contain restricted and privileged material for the sole use of the intended recipient(s). Any review, use, distribution or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive for the recipient), please contact the sender and delete all copies of the message. *Opening any content attached to this email implies running the risk of damaging your computer system due to the possible presence of viruses. Every reasonable precaution has been taken to minimize that risk. Liability for any damage sustained as a result of software viruses cannot be accepted. In general it is advisable to run your own virus checks before opening this or any other attachment. This e-mail message has been swept for the presence of known computer viruses.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20170315/00a3dbba/attachment.html>


More information about the Interest mailing list