diff options
author | Kirill Chibisov <contact@kchibisov.com> | 2023-07-20 08:21:47 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-20 08:21:47 +0000 |
commit | 044d9226016a70ed825a2d1e928b580de3f967b7 (patch) | |
tree | 8dc3a10634cd3553ecf7bf848449553a7c74f811 | |
parent | 52a004cce445eae63dd5b2385a352d60a130a382 (diff) | |
download | alacritty-044d9226016a70ed825a2d1e928b580de3f967b7.tar.gz alacritty-044d9226016a70ed825a2d1e928b580de3f967b7.zip |
Use bracketed paste only for multi-char IME input
Some IME setups do only `commit` single char input, like fcitx5 when
doing ru input.
-rw-r--r-- | alacritty/src/event.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/alacritty/src/event.rs b/alacritty/src/event.rs index 52222080..426b207e 100644 --- a/alacritty/src/event.rs +++ b/alacritty/src/event.rs @@ -1342,7 +1342,8 @@ impl input::Processor<EventProxy, ActionContext<'_, Notifier, EventProxy>> { WindowEvent::Ime(ime) => match ime { Ime::Commit(text) => { *self.ctx.dirty = true; - self.ctx.paste(&text, true); + // Don't use bracketed paste for single char input. + self.ctx.paste(&text, text.chars().count() > 1); self.ctx.update_cursor_blinking(); }, Ime::Preedit(text, cursor_offset) => { |