File and fopen

I'm using FileChooser to select file on disk. FileChooser results are File objects and from them I can get filenames.

Problem is that many filenames contain characters with codes larger than 127 (Chineese, Cyrilic,...).

How can I get filenames that 'fopen' will understand?

Why not use:

http://www.juce.com/api/classFileInputStream.html

Rail

Unfortunately this is not possible.

Then try http://www.juce.com/api/classString.html#ae79ca95309b6b8a7987e8b2f2efef297 (String::toWideCharPointer() with _wfopen()) or one of the relevant functions for your platform.

Rail

_wfopen is only available on Windows.

I found solution with short filenames and it seems to work.

String has a whole bunch of methods for getting character data out of it - for unixes you'd probably want to use something like myFile.getFullPathName().toRawUTF8()