Enter copies indent from the current line

Shift+Enter (GUI) and ESC-Enter (terminal) insert a raw newline.
Paste and prompts keep using Newline.
This commit is contained in:
2026-11-01 19:44:49 -08:00
parent a629a7fb0e
commit e701b416da
6 changed files with 42 additions and 12 deletions
+1 -5
View File
@@ -139,11 +139,7 @@ map_key(const SDL_Keycode key,
case SDLK_KP_ENTER:
k_prefix = false;
k_ctrl_pending = false;
if (mod & KMOD_SHIFT) {
out = {true, CommandId::SmartNewline, "", 0};
} else {
out = {true, CommandId::Newline, "", 0};
}
out = {true, KEnterCommand((mod & KMOD_SHIFT) != 0), "", 0};
return true;
case SDLK_ESCAPE:
k_prefix = false;