From fc5d58ad979d559d3b35dfe03ba9cad539d74dd1 Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Sun, 31 Oct 2021 11:20:12 +0100 Subject: [PATCH] tweaks: add two spaces and two comments, and drop an internal check --- doc/sample.nanorc.in | 4 ++-- src/global.c | 4 ++-- src/winio.c | 4 ---- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/doc/sample.nanorc.in b/doc/sample.nanorc.in index 58fe16d0..aa38d4fd 100644 --- a/doc/sample.nanorc.in +++ b/doc/sample.nanorc.in @@ -278,8 +278,8 @@ ## For quickly uppercasing or lowercasing the word under the cursor. ## (These effectively do a Ctrl+Right followed by a Shift+Ctrl+Left, ## and then pipe the selected text through a sed command.) -#bind Sh-M-U "Oc|sed 's/.*/\U&/' " main -#bind Sh-M-L "Oc|sed 's/.*/\L&/' " main +# bind Sh-M-U "Oc|sed 's/.*/\U&/' " main +# bind Sh-M-L "Oc|sed 's/.*/\L&/' " main ## If you would like nano to have keybindings that are more "usual", ## such as ^O for Open, ^F for Find, ^H for Help, and ^Q for Quit, diff --git a/src/global.c b/src/global.c index f3257307..a9a78e9c 100644 --- a/src/global.c +++ b/src/global.c @@ -1356,10 +1356,10 @@ void shortcut_init(void) add_to_sclist((MMOST|MBROWSER|MYESNO) & ~MFINDINHELP, "M-X", 0, do_toggle_void, NO_HELP); add_to_sclist(MMAIN, "M-C", 0, do_toggle_void, CONSTANT_SHOW); add_to_sclist(MMAIN, "M-S", 0, do_toggle_void, SOFTWRAP); - add_to_sclist(MMAIN, "M-$", 0, do_toggle_void, SOFTWRAP); + add_to_sclist(MMAIN, "M-$", 0, do_toggle_void, SOFTWRAP); /* Legacy keystroke. */ #ifdef ENABLE_LINENUMBERS add_to_sclist(MMAIN, "M-N", 0, do_toggle_void, LINE_NUMBERS); - add_to_sclist(MMAIN, "M-#", 0, do_toggle_void, LINE_NUMBERS); + add_to_sclist(MMAIN, "M-#", 0, do_toggle_void, LINE_NUMBERS); /* Legacy keystroke. */ #endif add_to_sclist(MMAIN, "M-P", 0, do_toggle_void, WHITESPACE_DISPLAY); #ifdef ENABLE_COLOR diff --git a/src/winio.c b/src/winio.c index 640c0538..d05c30de 100644 --- a/src/winio.c +++ b/src/winio.c @@ -842,10 +842,6 @@ int parse_escape_sequence(int starter) keycode = convert_SS3_sequence(key_buffer, key_buffer_len, &consumed); else if (starter == '[') keycode = convert_CSI_sequence(key_buffer, key_buffer_len, &consumed); -#ifndef NANO_TINY - else - die("Bad sequence starter -- please report a bug\n"); -#endif /* Remove the consumed sequence bytes from the keystroke buffer. */ key_buffer_len -= consumed;