ref: e94c2faaae73378752158690f8421efbf6fa76c8
parent: 50d1c1cc747afc916c43efe4f005754105d81a08
author: linear_sunrise <37690578+linearsunrise@users.noreply.github.com>
date: Sat Dec 28 15:06:39 EST 2019
Backspace character deletion (#51) * added backspace deletion in append and insert
--- a/tui_main.c
+++ b/tui_main.c
@@ -2364,6 +2364,14 @@
break;
case 127: // backspace in terminal.app, apparently
case KEY_BACKSPACE:
+ if (ged_state.input_mode == Ged_input_mode_append) {
+ ged_dir_input(&ged_state, Ged_dir_left, 1);
+ ged_input_character(&ged_state, '.');
+ ged_dir_input(&ged_state, Ged_dir_left, 1);
+ } else {
+ ged_input_character(&ged_state, '.');
+ }
+ break;
case CTRL_PLUS('h'):
case KEY_LEFT:
ged_dir_input(&ged_state, Ged_dir_left, 1);