Skip to content
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

horizontal cursor movement breaks emoji #859

Closed
0x-voidptr opened this issue Jun 8, 2024 · 5 comments
Closed

horizontal cursor movement breaks emoji #859

0x-voidptr opened this issue Jun 8, 2024 · 5 comments
Labels
bug Something isn't working PR Contributors are encouranged to submit a pull request. Just ask in case you are interested.

Comments

@0x-voidptr
Copy link

Describe the bug
Using the cursor movement feature of the horizontal spacebar swipe gesture around emojis will sometimes place the cursor in a spot where any typing will break the emoji. I believe this is because the cursor is being aligned to the byte rather than to the character/codepoint.

To Reproduce
Type out a few emojis and swipe into the middle, then try to type something. Around half of the time it will break.

Expected behavior
Expected: 😊😊t😊😊
Result: 😊😊�t�😊

App version
Version 1.3, via f-droid

Device:

  • Samsung Galaxy A54, stock Android 14
  • Samsung Galaxy Tab S7+, stock Android 13
@0x-voidptr 0x-voidptr added the bug Something isn't working label Jun 8, 2024
@ccoVeille
Copy link

I'm also experiencing this issue.

Same configuration: stock Android 14

@Helium314 Helium314 added the PR Contributors are encouranged to submit a pull request. Just ask in case you are interested. label Jun 10, 2024
@Helium314
Copy link
Owner

This is essentially the same as #22. Should be easy to somewhat improve (do the swipe in codepoints instead of chars), but hard to really fix, because there are also multi-codepoint emojis. And whether those display as a single emoji or multiple depends on your Android version

@0x-voidptr
Copy link
Author

the left/right toolbar key functionality appears to work as expected for both the simpler cases and the more complex ones in the issue above. using this method to fix cursor movement issues seems straightforward in theory, although extending this fix to backspace behaviour may prove more complicated

@Helium314
Copy link
Owner

I don't remember exactly, but I think there were issues when spamming left/right key events as part of such fast cursor movement (and in general, sending key events is discouraged)

@ccoVeille
Copy link

No more bug for me in 2.0-beta2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working PR Contributors are encouranged to submit a pull request. Just ask in case you are interested.
Projects
None yet
Development

No branches or pull requests

3 participants