Skip to content

Conversation

@chaeya
Copy link

@chaeya chaeya commented Aug 9, 2025

This commit implements proper input method (IME) support that was missing since the Clutter API migration in Cinnamon 5.0+. The original inputMethod.js file created during the 2021 API transition contained only empty method stubs, causing input method frameworks (ibus, fcitx, nimf, kime, xim, etc.) to fail in menu search boxes and Alt+F2 run dialogs.

Changes:

  • Implement GTK IMMulticontext integration for universal IME support
  • Add Clutter to GDK event conversion for proper key event handling
  • Implement preedit text display and management for composition
  • Add proper focus handling and input method state management
  • Set up client window and cursor location for IME positioning

Fixes multiple long-standing issues:

  • Menu search box not accepting CJK input (Korean, Japanese, Chinese)
  • Alt+F2 run dialog not supporting input method switching
  • All major Linux input method frameworks affected

Closes: #11115, #11610, #11713
Tested-by: HamoniKR team with Korean input (nimf, ibus, fcitx)

This commit implements proper input method (IME) support that was missing
since the Clutter API migration in Cinnamon 5.0+. The original inputMethod.js
file created during the 2021 API transition contained only empty method stubs,
causing input method frameworks (ibus, fcitx, nimf, kime, xim, etc.) to fail
in menu search boxes and Alt+F2 run dialogs.

Changes:
- Implement GTK IMMulticontext integration for universal IME support
- Add Clutter to GDK event conversion for proper key event handling
- Implement preedit text display and management for composition
- Add proper focus handling and input method state management
- Set up client window and cursor location for IME positioning

Fixes multiple long-standing issues:
- Menu search box not accepting CJK input (Korean, Japanese, Chinese)
- Alt+F2 run dialog not supporting input method switching
- All major Linux input method frameworks affected

Closes: linuxmint#11115, linuxmint#11610, linuxmint#11713
Tested-by: HamoniKR team with Korean input (nimf, ibus, fcitx)
@mtwebster
Copy link
Member

Hi thanks for this, but there is already a pending pull request (along with related changes in other packages). Testing welcome!

#12758

@mtwebster mtwebster closed this Aug 9, 2025
@Mr-Spade
Copy link

Mr-Spade commented Nov 2, 2025

Hi @mtwebster, thank you so much for your excellent work on improving CJK and input method support!

I've been following the related PRs and noticed that the merged #12758 appears to implement a solution that is tightly coupled to IBus (using ibusManager.js and an IBus-specific InputMethod client).

I'm bringing this up because I saw that this PR was closed as a duplicate. However, it seemed to take a functionally different approach by using Gtk.IMMulticontext.

As you know, Gtk.IMMulticontext acts as a more generic abstraction layer, providing support for not only IBus, but also Fcitx, Fcitx5, nimf, scim, and xim right out of the box.

Given that a large number of users (especially in the CJK community) rely heavily on other frameworks like Fcitx5, would it be possible to reconsider the Gtk.IMMulticontext implementation from this PR? It provides a functionally broader and more universal solution that would benefit all input method users, not just those on IBus.

Perhaps the key Gtk.IMMulticontext parts from this PR could be extracted and revisited to provide this more universal support for Cinnamon?

Thanks again for your time and consideration!

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.

[BUG] Can't change language in startmenu searchbar

3 participants