C++ hasn‘t even proper Unicode handling integrated. std::string is a mess in my opinion.
Beste Grüße / Best regards, Alexander Nassian > Am 18.10.2019 um 02:30 schrieb Henry Skoglund <[email protected]>: > > Hi, while writing lots of QString string fiddling code (keyboard macro > utility) I feel something tugging at my sleeve: > the upcoming C++20, looking at std::format(), it seems really handy, e.g.: > > std::string s = std::format("String '{}' has {} characters\n", string, > string.length()); > > // for a German flavor you can use arg # > std::string s = std::format("{1} Zeichen lang ist die Zeichenkette '{0}'\n", > string, string.length()); > > // lots of formatting options with a ':' inside the curlies > std::string s = std::format("{0:b} {0:d} {0:x}", 42); // s == "101010 42 2a" > > Using QString::arg() works fine but it's getting harder to ignore all the new > C++ stuff and C++20 looks to be one of the bigger additions to the language > since C++11. > > Perhaps the time has come to think about a retirement plan for QString? > > Rgrds Henry > > _______________________________________________ > Development mailing list > [email protected] > https://lists.qt-project.org/listinfo/development -- — bitshift dynamics GmbH Neudorfer Str. 1, 79541 Lörrach Registergericht: Amtsgericht Freiburg i. Breisgau, HRB 713747 Geschäftsführer: Alexander Nassian, Markus Pfaffinger http://www.bitshift-dynamics.de <http://www.bitshift-dynamics.de/> Zentrale: +49 762158673 - 0 Fax: +49 7621 58673 - 90 Allgemeine Anfragen: [email protected] <mailto:[email protected]> Technischer Support: [email protected] <mailto:[email protected]> Buchhaltung: [email protected] <mailto:[email protected]>
_______________________________________________ Development mailing list [email protected] https://lists.qt-project.org/listinfo/development
