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

macOS: Fix IME action when deleting last char #13385

Merged
merged 2 commits into from
Jun 25, 2024

Conversation

JunkuiZhang
Copy link
Contributor

@JunkuiZhang JunkuiZhang commented Jun 22, 2024

Closes #12862

2024-06-22.16.28.57.mov

Release Notes:

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Jun 22, 2024
@zed-industries-bot
Copy link

Warnings
⚠️
macOS: Fix IME action when deleting last char
^

Write PR titles using sentence case.

Have feedback on this plugin? Let's hear it!

Generated by 🚫 dangerJS against aea28dd

@@ -1248,7 +1251,8 @@ extern "C" fn handle_key_event(this: &Object, native_event: id, key_equivalent:
let is_composing =
with_input_handler(this, |input_handler| input_handler.marked_text_range())
.flatten()
.is_some();
Copy link
Contributor Author

@JunkuiZhang JunkuiZhang Jun 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is_composing will be false when deleting the last char during IME composing, then KeyDown("backspace") is propagated, leads to mis-deleting other char.

@ConradIrwin ConradIrwin merged commit 76ab9e4 into zed-industries:main Jun 25, 2024
11 checks passed
@ConradIrwin
Copy link
Collaborator

THanks!

@JunkuiZhang JunkuiZhang deleted the macos/ime-fix branch June 25, 2024 08:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed The user has signed the Contributor License Agreement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

IME delete misalignment after output
4 participants