[core] Re: Win32 Port

Lukáš Lalinský lalinsky at gmail.com
Sat Jun 10 17:31:27 CEST 2006


Indy Sams wrote:
> Hello Lukáš,
> 
> lol, I guess so. I only went back a couple of months on the dev list looking for
> a win32 port then just made one myself. Yours is more complete exported-class wise
> and the Unicode filename support was a nice touch. Does that work well on Unicode
> filenames? I switched to taglib basically for the purpose of supporting Unicode
> for my international users and I noticed it won't open a lot of filenames because
> of non-standard characters in the filenames.

Yes, that was the point. Non wide-char version of fopen uses native Windows
encoding, which means you can't open files that contain characters outside of
this encoding. So I had to use _wfopen, and as the application I wrote it for
stores all strings in UTF-8 it was easier for me to reuse the File::File(const
char *file) constructor and decode from UTF-8 to UTF-16 there. More WinAPI-like
approach would be probably adding a new File::File(LPWSTR file) constructor for
Unicode file names, and keeping the other one for file names in native Windows
encodings.

Lukas


More information about the taglib-devel mailing list