Re: [boost] Boost.Filesystem i18n mini-review

Beman Dawes wrote:
At 04:42 AM 7/20/2005, Jan Hermelink wrote:
Replacing the current implementation thru a simple narrow conversion helps as workaround.
My understanding (which could be faulty) is that there is no general way to do such a wide to narrow conversion that always works.
I don't know. It works with filenames with german characters but I can't say for filenames with e.g. CJK characters. Another idea: - Get a WIN32 file handle with CreateFileW() - Get filename from handle: http://msdn.microsoft.com/library/en-us/fileio/fs/obtaining_a_file_name_ from_a_file_handle.asp - use thereby the "Ansi" function to get the "ansi" filename (GetMappedFileNameA()) However I have not tested this... Jan

"Jan Hermelink" <Jan.Hermelink@metalogic.de> wrote in message news:EB650214CCEA984983BC694221A6D3BF01187C@JUPITER.muenchen.metalogic.de...
Beman Dawes wrote:
At 04:42 AM 7/20/2005, Jan Hermelink wrote:
Replacing the current implementation thru a simple narrow conversion helps as workaround.
My understanding (which could be faulty) is that there is no general way to do such a wide to narrow conversion that always works.
I don't know. It works with filenames with german characters but I can't say for filenames with e.g. CJK characters.
Another idea: - Get a WIN32 file handle with CreateFileW() - Get filename from handle: http://msdn.microsoft.com/library/en-us/fileio/fs/obtaining_a_file_name_ from_a_file_handle.asp - use thereby the "Ansi" function to get the "ansi" filename (GetMappedFileNameA())
However I have not tested this...
I don't see how that could work unless the codepage is correct, but like you I haven't actually tested. --Beman
participants (2)
-
Beman Dawes
-
Jan Hermelink