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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

vim: entering insert mode with 'a' can place cursor in middle of emojis #4108

Closed
kevinushey opened this issue Nov 5, 2019 · 7 comments 路 Fixed by #4933
Closed

vim: entering insert mode with 'a' can place cursor in middle of emojis #4108

kevinushey opened this issue Nov 5, 2019 · 7 comments 路 Fixed by #4933

Comments

@kevinushey
Copy link
Contributor

To reproduce, in kitchen sink:

https://ace.c9.io/build/kitchen-sink.html

  1. Turn on Vim keybindings,
  2. Copy and paste the emoji 馃槆into the editor,
  3. Press a to enter insert mode "after" the character under the carat,
  4. Notice that the carat is placed "in the middle" of the emoji.

At this point, pressing Backspace also removes the first element of the surrogate pair making up the emoji, leaving behind the other (now invalid) piece.

@github-actions
Copy link

github-actions bot commented May 9, 2022

This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.

@kevinushey
Copy link
Contributor Author

Appears to still be an issue.

@andrewnester
Copy link
Contributor

I tried to reproduce this on the latest version of Ace in kitchen sink using your steps and it does not seem to be reproducible. Could you please confirm that?

@kevinushey
Copy link
Contributor Author

Very weird... I tried to reproduce again, and it seems like it reproduces inconsistently? For example:

Screen.Recording.2022-06-29.at.11.07.39.AM.mov

Using x to delete a character seems to always delete the first "half" of the emoji, though.

@andrewnester
Copy link
Contributor

This PR fixes the issue in our dependency replit/codemirror-vim#49

Once it's merged we can update the dependency

@andrewnester
Copy link
Contributor

Fixed by this PR #4933 and released in version 1.11.1

@andrewnester
Copy link
Contributor

Added additional fixes and released in 1.11.2
https://github.com/ajaxorg/ace/releases/tag/v1.11.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants