The GTK IM module only emitted the commit signal when the key was
eaten (r != 0). But when a non-matching key is pressed mid-composition
the engine commits the pending preedit and returns eaten=0 so the raw
key passes through, sending a commit string with eaten=0. GTK dropped
it, silently losing the composed text (e.g. Hangul "ㅇ" + "?" yielded
only "?").
Commit whenever a commit string is present, matching the wayland, ibus
and xim frontends.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>