Skip to content

Add one-step Korean input setup - #11719

Open
MoerAI wants to merge 2 commits into
omacom:quattrofrom
MoerAI:korean-input-setup
Open

MoerAI wants to merge 2 commits into
omacom:quattrofrom
MoerAI:korean-input-setup

Conversation

@MoerAI

@MoerAI MoerAI commented Sep 13, 2026

Copy link
Copy Markdown

Korean users land on an Omarchy that can't type Hangul. The pieces are all there — fcitx5 runs in every session for the CapsLock compose sequences, and noto-fonts-cjk already renders Korean — but getting from there to typing 한글 means knowing to omarchy pkg add fcitx5-hangul, then opening fcitx5-configtool (which the launcher hides) to add the engine to the input method group. Windows and macOS finish setup with a working Korean IME; this closes that gap in one step.

What this does

  • omarchy-setup-input-hangul (omarchy setup input hangul) installs fcitx5-hangul, restarts the supervised fcitx5 so it discovers the new engine, waits for it to answer, and appends hangul to the current input method group over D-Bus (org.fcitx.Fcitx.Controller1 InputMethodGroupInfoSetInputMethodGroupInfoSave). Existing engines stay in place, and a rerun is a no-op on the group. Without a desktop session it says so and exits 1 rather than touching anything.
  • Setup > Input Method > Hangul (Korean) in the Omarchy menu runs it in the presentation terminal.
  • Manual: a Typing in Korean section under Keyboard, Mouse, Trackpad — the 한/영 / Ctrl+Space toggle, the 한자 / F9 Hanja key, the korean:ralt_hangul,korean:rctrl_hanja xkb options for keyboards without dedicated keys, and the QWERTY layout Hangul needs on Dvorak or Colemak.
  • Tests: test/shell.d/input-korean-test.sh pins the exact D-Bus rewrite, idempotence, the stopped-fcitx5 failure path, and that the fcitx5 state probe stays out of the terminal; menu-test.sh covers the entry; test/acceptance.d/input-korean-test.sh types Dubeolsik gks into a terminal and expects .

What it deliberately doesn't do

  • No global fcitx5 config is written. fcitx5's stock trigger keys are Control+space, Zenkaku_Hankaku and Hangul (globalconfig.cpp), and xkb's shared symbols/pc maps the 한/영 and 한자 keys to Hangul / Hangul_Hanja on every layout, so a Korean keyboard toggles out of the box and fcitx5-hangul's defaults (Dubeolsik, Hanja on Hangul_Hanja / F9) need no hangul.conf.
  • No Chromium/Electron flags. --enable-wayland-ime is no longer needed: Chromium's kWaylandTextInputV3 feature is ENABLED_BY_DEFAULT and IsImeEnabled() returns true when it is on (ui_base_features.cc, wayland_input_method_context.cc), so the Chromium Omarchy ships already talks text-input-v3 to Hyprland and on to fcitx5. The Arch wiki guidance predates that change.
  • No locale, translation, install-time keyboard choice (Offer Korean as an install-time keyboard choice #9299) or bar indicator — those are separate concerns with their own PRs.

This mirrors #9634 (one-step Japanese input) on purpose: same command shape, same D-Bus group rewrite, same setup.input-method parent, so both can land and the menu reads Input Method > Hangul (Korean) / Mozc (Japanese). If #9634 goes first, the only conflict is the identical parent line. One thing found here that applies there too: a bare fcitx5-remote --check prints the input state (2) on stdout once fcitx5 answers, so the readiness probe has to be silenced or the presentation terminal shows a stray digit.

Verification

Run in an archlinux container (bind-mounted checkout, bash 5.3, jq 1.8, node 26):

Check Result
test/shell.d/input-korean-test.sh 3 ok: fresh group gets SetInputMethodGroupInfo ssa(ss) Default us 3 keyboard-us "" keyboard-de de hangul "" + Save; hangul already present → no rewrite; fcitx5 down → exit 1, no busctl
Regression check for the probe fix Reverting only the >/dev/null 2>&1 fails the suite with the stray 2
test/shell.d/menu-test.sh, menu-guards-test.sh Pass
./test/cli Pass (metadata lint, omarchy setup input hangul --help renders)
./test/shell No new failures versus the same container before the change
Command stdout with stubbed pkg-add/busctl/fcitx5-remote Exactly the two ready lines, exit 0, directly and via omarchy setup input hangul

Not verified: test/acceptance.d/input-korean-test.sh needs the omarchy-iso VM harness and was only syntax-checked; the full command against a live fcitx5 was exercised through stubs that answer with the real D-Bus shapes.

Omarchy already runs fcitx5 in every session for the CapsLock compose
sequences, so Korean was only ever an engine and a group entry away --
but reaching it meant installing fcitx5-hangul by hand and wiring it in
through fcitx5-configtool, which the launcher hides.

Setup > Input Method > Hangul (Korean) now installs fcitx5-hangul,
restarts the supervised fcitx5 so it discovers the engine, and appends
hangul to the current input method group over D-Bus, leaving any engine
the user added earlier in place. fcitx5's stock trigger keys already
include the Hangul keysym the 한/영 key emits, so no global config is
written; Ctrl+Space covers keyboards without one.

The manual covers the toggle and Hanja keys, the xkb options that put
한/영 and 한자 on Right Alt and Right Ctrl for keyboards without them,
and the QWERTY layout Hangul needs on Dvorak or Colemak.
Runs the setup command, checks fcitx5-hangul is installed and registered
with fcitx5, then types Dubeolsik g k s into a terminal and expects 한
back. Skips when the package is missing and no sudo password is
provided, the way the sshd hardening exercise does.
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