From 630ba680e5f88fe1cab5d302bac1265c449fc7b7 Mon Sep 17 00:00:00 2001 From: Kiyoon Kim Date: Fri, 20 Nov 2026 17:46:46 +0900 Subject: [PATCH] macos: Fix IME commit being lost when a key ends composition (#8109) Clearing ime_text before interpretKeyEvents makes hasMarkedText() answer NO while a composition is active. AppKit consults it when applying text that an input method commits during the key event, and discards commit text arriving together with a function key. Korean IMEs finalize the composing syllable when an arrow key is pressed, so that syllable was lost instead of being committed. ime_text is maintained by setMarkedText/insertText/unmarkText, so removing the pre-clear leaves the state correct. refs: #6907 --- window/src/os/macos/window.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/window/src/os/macos/window.rs b/window/src/os/macos/window.rs index fc8e9fa94..19f3562b3 100644 --- a/window/src/os/macos/window.rs +++ b/window/src/os/macos/window.rs @@ -2722,7 +2722,6 @@ impl WindowView { let mut inner = myself.inner.borrow_mut(); inner.key_is_down.replace(key_is_down); inner.ime_state = ImeDisposition::None; - inner.ime_text.clear(); } unsafe {