sokol_app.h Win32: __argv doesn't actually provide UTF-8 strings...

Created on 10 Apr 2019  路  3Comments  路  Source: floooh/sokol

...need to use __wargv and convert that to UTF-8 myself.

(Correction: looks like __wargv is null unless compiled with UNICODE define, need to find another solution)

PS: but maybe it works to convert from the codepage-encoded __argv to UTF-8 MultiByteToWide (codepage -> UTF-16) followed by WideToMultiByte (UTF16 -> UTF8)

PPS: alternatively GetCommandLineW() + CommandLineToArgvW(), and convert that to UTF-8

bug

All 3 comments

I can help with this. I had success with GetCommandLineW() + CommandLineToArgvW() in my own platform layer.

If you find the time to provide a PR that would be great :)

ok fixed in #211

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mhalber picture mhalber  路  5Comments

pjako picture pjako  路  3Comments

datgame picture datgame  路  6Comments

ilar81 picture ilar81  路  7Comments

serkonda7 picture serkonda7  路  4Comments