I'm writing an application for Linux and Windows hosts. It has to process files and directories that can often contain various japanese, korean, etc. UTF-8 characters in their names. Everything works fine on Linux, however on Windows they are never processed or displayed correctly, what leads to incorrect and broken paths.
toKString()
function returns correct values on Linux, and broken ones on Windows, I'm assuming because of some Windows or mingw encoding-related caveat that I can't figure out.
I created a simple project to demonstrate the issue, does anyone know how to deal with this?
https://gitlab.com/Chazoshtare/encoding-issue-kn/-/tree/master
The code base contains some hard coded strings, which will likely cause character encoding issues (you are dealing with two different platforms which don't use the same character encoding). Have you looked at moving the strings into a separate text file?