Skip to content

fix(watch): switch IME to Chinese after bopomofo-daqian correction#2

Merged
winterdrive merged 5 commits into
mainfrom
fix/issue-1-ime-switch
Jun 11, 2026
Merged

fix(watch): switch IME to Chinese after bopomofo-daqian correction#2
winterdrive merged 5 commits into
mainfrom
fix/issue-1-ime-switch

Conversation

@winterdrive

@winterdrive winterdrive commented Jun 11, 2026

Copy link
Copy Markdown
Owner

Summary

  • After migao-watch pastes corrected bopomofo-daqian text, calls ImmSetConversionStatus with IME_CMODE_NATIVE to switch the foreground window's IME back to Chinese input mode
  • Only triggers for bopomofo-daqian rule; english-from-bopomofo corrections leave IME as-is
  • Requires new imm feature in winapi dependency

Closes #1

After correcting garbled text, call ImmSetConversionStatus(IME_CMODE_NATIVE)
so the foreground window returns to Chinese input mode. Resolves #1.
After correcting garbled text, call ImmSetConversionStatus(IME_CMODE_NATIVE)
so the foreground window returns to Chinese input mode. Resolves #1.
…oses #1)

- Replace ImmGetContext (cross-process null) with ImmGetDefaultIMEWnd + WM_IME_CONTROL
- Layer 1: WM_INPUTLANGCHANGEREQUEST for ENG-keyboard users
- Layer 2: WM_IME_CONTROL to MS Bopomofo IME window (validated on Win11)
- Layer 3: Shift injection after Ctrl/Alt/R physically released (fallback)
- Add examples/ime_test.rs standalone probe used to validate the approach
- Add docs/dev-ime-switch.md development notes
- docs: add Windows-only notice + macOS/Linux alternatives to all README langs
@winterdrive winterdrive merged commit 251cc87 into main Jun 11, 2026
5 checks passed
@winterdrive winterdrive deleted the fix/issue-1-ime-switch branch June 11, 2026 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

轉換完應切到中文輸入法

1 participant