summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKirill Chibisov <contact@kchibisov.com>2024-03-21 08:00:06 +0400
committerGitHub <noreply@github.com>2024-03-21 08:00:06 +0400
commitfd1a3cc79192d1d03839f0fd8c72e1f8d0fce42e (patch)
tree743d0ae3249c5f42065de3238332e66323491c7e
parentfe88aaa0855283d689dc41d531db916404ef9c51 (diff)
Fix kitty encoding used for char input without text
On Windows some key combinations for regular text input, like Ctrl+1 don't have any text attached, so they were generating the kitty escape sequence even when they shouldn't.
-rw-r--r--CHANGELOG.md1
-rw-r--r--alacritty/src/input/keyboard.rs2
2 files changed, 2 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7dadf41c..cbbd4bb8 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -27,6 +27,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Config keys are available under proper names
- Build failure when compiling with x11 feature on NetBSD
- Hint `Select` action selecting the entire line for URL escapes
+- Kitty encoding used for regular keys when they don't carry text
### Changed
diff --git a/alacritty/src/input/keyboard.rs b/alacritty/src/input/keyboard.rs
index b7635bd9..afb23eb5 100644
--- a/alacritty/src/input/keyboard.rs
+++ b/alacritty/src/input/keyboard.rs
@@ -347,7 +347,7 @@ impl SequenceBuilder {
associated_text: Option<&str>,
) -> Option<SequenceBase> {
let character = match key.logical_key.as_ref() {
- Key::Character(character) => character,
+ Key::Character(character) if self.kitty_seq => character,
_ => return None,
};