QString::fromLatin1
Waldo Bastian
bastian at kde.org
Wed Jul 9 09:23:39 BST 2003
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Wednesday 09 July 2003 04:27, Benjamin Meyer wrote:
> In kmainwindow.cpp when storing settings it wraps the string with
> QString::fromLatin1() Such as:
> "config->writeEntry(QString::fromLatin1("StatusBar"), entryList, ';');"
> Some of the classes do this, some don't. What is the value of doing this?
> Should it be done at the KConfig level rather then sometimes? Is it
> historical? Can it be removed?
I guess it is historical.
It should be removed. writeEntry is overloaded and can either take QString or
const char * as first argument. Converting const char * explicitly to QString
is not necassery and slower.
Cheers,
Waldo
- --
bastian at kde.org -=|[ SuSE, The Linux Desktop Experts ]|=- bastian at suse.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
iD8DBQE/C9ELN4pvrENfboIRAmA9AJwO8B20gktIrA7jD14JPR02LASxOgCfaPLj
8YC/QpzCVwoD81Lx/JvjoT4=
=LpDh
-----END PGP SIGNATURE-----
More information about the kde-core-devel
mailing list