[Qt-interest] QFileInfoList and UTF-8
Mathieu Malaterre
mathieu.malaterre at gmail.com
Thu Feb 24 13:12:53 CET 2011
On Thu, Feb 24, 2011 at 1:10 PM, Nikos Chantziaras <realnc at arcor.de> wrote:
>> What am I missing from the call to entryInfoList ? I am trying to use
>> a 3rd party library which expect filenames to be specified as UTF-8.
>
> You can't assume the local filesystem uses UTF-8. You need to use
> QString::fromLocal8Bit():
>
> QDir dir( QString::fromLocal8Bit(dirname) );
Fantastic ! Thanks so much !
--
Mathieu
More information about the Qt-interest-old
mailing list