From ab35f6618bc8beb4543cbc7c62332f82d7d5699c Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Sat, 22 Mar 2025 15:19:53 +0300 Subject: added `P` command as a reverse form of `W` * All the movement commands have shortcuts for their negative forms: `R` instead of `-C`, `B` instead of `-L`. Therefore there was always the need for a `-W` shortcut as well. * `P` is a good choice because it is a file IO command in TECO-11, that does not make sense supporting. In Video TECO it toggles between display windows (ie. split screens) and I do not plan to support multiple windows in SciTECO. * Added to the cheat sheet. --- src/core-commands.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/core-commands.c') diff --git a/src/core-commands.c b/src/core-commands.c index f39f6f9..4abf38b 100644 --- a/src/core-commands.c +++ b/src/core-commands.c @@ -659,7 +659,8 @@ teco_state_start_input(teco_machine_main_t *ctx, gunichar chr, GError **error) ['R'] = {&teco_state_start, teco_state_start_reverse}, ['L'] = {&teco_state_start, teco_state_start_line}, ['B'] = {&teco_state_start, teco_state_start_back}, - ['W'] = {&teco_state_start, teco_state_start_word}, + ['W'] = {&teco_state_start, teco_state_start_words}, + ['P'] = {&teco_state_start, teco_state_start_words_back}, ['V'] = {&teco_state_start, teco_state_start_delete_words}, ['Y'] = {&teco_state_start, teco_state_start_delete_words_back}, ['='] = {&teco_state_start, teco_state_start_print}, -- cgit v1.2.3