i want to open a file with Texture.new(path) where i got the filename/path using lfs.dir(). this works fine but when the file contains accented characters like 'é' then i get an error that " No such file or directory". what should i do? ty
now thinking about it that was an issue with lfs and now lfs seems to work fine, just the filename/path i get cannot be used in Texture.new. also it seems that io.open has the same issues with accented characters.
Yes, you should be able to do that on lua, you can use utf8 functions to transform your utf8 path into chars (code points), then use a table to encode them into a string using cp1252 mapping
that switching you mentioned would be probably most comfortable. alternatively there could be some conversion as a plugin, like https://github.com/ittner/lua-iconv
Comments
https://forum.giderosmobile.com/discussion/comment/63226#Comment_63226
while it's written there that it is corrected, now it seems to have issues (again?).
now thinking about it that was an issue with lfs and now lfs seems to work fine, just the filename/path i get cannot be used in Texture.new. also it seems that io.open has the same issues with accented characters.
Fragmenter - animated loop machine and IKONOMIKON - the memory game
https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/fopen-wfopen?view=msvc-170
https://en.wikipedia.org/wiki/Windows-1252
Likes: MoKaLux
Fragmenter - animated loop machine and IKONOMIKON - the memory game
is there a way to do this with current gideros?
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Fragmenter - animated loop machine and IKONOMIKON - the memory game
Likes: keszegh, MoKaLux