-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Trying to erase none utf8 characters throw errors #55
Comments
What happens when you type an emoji? I assume the font you use doesn't render it or do you actually have a font that renders the emoji? |
I tried the utf8 module in the same way as the backspace key is handled and it generates the correct result:
|
Odd. Doing the same within Gooey gives me this call stack.
What I am doing is super straight forward. Simply inputting a smiley triggers it in this case.
|
Emojis more investigation. In Java an emoji can't be represented in a single UTF-16 character, it actually needs two. The emoji is converted into a surrogate pair, one high and one low character. https://developers.redhat.com/blog/2019/08/16/manipulating-emojis-in-java-or-what-is-%F0%9F%90%BB-1/ In Defold we simply take the codepoint of the the two UTF-16 characters and encode these to UTF-8 and forward to Lua
I'm still not sure how this should be handled to be honest and I've already spent too much time on this. Investigation has to continue later. |
Easily reproduced with a emoji such as 😄 while typing on a phone.
@britzl How do you think we should handle this?
The text was updated successfully, but these errors were encountered: