From f8a9dbe2b93cd3d477e8a7d83cced1fb973adc7b Mon Sep 17 00:00:00 2001 From: DashingCat <65317616+DashingCat@users.noreply.github.com> Date: Wed, 1 Apr 2026 21:44:36 +0200 Subject: [PATCH 1/2] Support ctrl+backspace in OuiMapSearch --- Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs b/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs index 5af9b4254..63d5e75f0 100644 --- a/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs +++ b/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs @@ -175,7 +175,12 @@ public void OnTextInput(char c) { } else if (c == (char) 8) { // Backspace - trim. if (search.Length > 0) { - search = search.Substring(0, search.Length - 1); + if (MInput.Keyboard.CurrentState.IsKeyDown(Keys.LeftControl) + || MInput.Keyboard.CurrentState.IsKeyDown(Keys.RightControl)) { + search = ""; + } else { + search = search.Substring(0, search.Length - 1); + } Audio.Play(SFX.ui_main_rename_entry_backspace); goto ValidButton; } else { From 291c94cae3b14fb2b735e5909c2ff015d98385f5 Mon Sep 17 00:00:00 2001 From: DashingCat <65317616+DashingCat@users.noreply.github.com> Date: Thu, 25 Jun 2026 16:21:59 +0000 Subject: [PATCH 2/2] Allow clearing word by word Co-authored-by: Wartori <72220838+Wartori54@users.noreply.github.com> --- Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs b/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs index 63d5e75f0..a63b343fd 100644 --- a/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs +++ b/Celeste.Mod.mm/Mod/UI/OuiMapSearch.cs @@ -177,7 +177,11 @@ public void OnTextInput(char c) { if (search.Length > 0) { if (MInput.Keyboard.CurrentState.IsKeyDown(Keys.LeftControl) || MInput.Keyboard.CurrentState.IsKeyDown(Keys.RightControl)) { - search = ""; + int idx = search.Length - 1; + while (idx >= 0 && char.IsWhiteSpace(search[idx])) idx--; + while (idx >= 0 && !char.IsWhiteSpace(search[idx])) idx--; + search = search.Substring(0, idx+1); + } else { search = search.Substring(0, search.Length - 1); }