Hello, maybe someone has solved the problem with unicode when working with strings?!
I wanna convert string with unicode chars to table and back, but how knows. This return only �
--- solved
Why would you want to convert a string with unicode into a table?
Anyway, you will have to take into account the multi byte characters if you want to do this. There are no build in methods to handle unicode/utf-8 properly.
[QUOTE=Ivitokun;47391706]--- solved[/QUOTE]
Thanks for helping the community!
[code]
for _, char in string.gmatch( your_string, "[%z\1-\x7F\xC2-\xF4][\x80-\xBF]*" ) do
-- Insert your multi-byte char in to a table here
end
[/code]
This pattern is for matching utf8 codepoints.
[QUOTE=Willox;47393190]Thanks for helping the community!
[code]
for _, char in string.gmatch( your_string, "[%z\1-\x7F\xC2-\xF4][\x80-\xBF]*" ) do
-- Insert your multi-byte char in to a table here
end
[/code]
This pattern is for matching utf8 codepoints.[/QUOTE]
Oh... Sorry I just was busy and forgot about it and I solve it just download glib's scripts
Sorry, you need to Log In to post a reply to this thread.