On quarta-feira, 26 de dezembro de 2012 16.42.44, Nikos Chantziaras wrote: > > Why do you need the codec name anyway? > > So that I can tell another library what encoding to use for filenames > when it wants to create files.
Can't you tell it to use the default? By the way, on Windows you should always choose UTF-16, both on the Qt and the 3rd-party library's side. The Windows "A" (ANSI) API as well as the POSIX- style CRT API are unable to deal with all the possible file names that the Windows "W" (Wide) API can deal with. QFile already uses the "W" API, so you don't have to do anything. But that means you must not use QFile::encodeName on Windows. Simply pass the QString's original UTF-16 data and tell the other library to use the "W" API too. Anything else, on Windows, is dead-on-arrival. -- Thiago Macieira - thiago.macieira (AT) intel.com Software Architect - Intel Open Source Technology Center
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest