Mercurial > vim
diff src/os_unix.c @ 24242:d3cabf12c991 v8.2.2662
patch 8.2.2662: there is no way to avoid some escape sequences
Commit: https://github.com/vim/vim/commit/7007e31bde75b6360a1b54c7572e4f855458f37d
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Mar 27 12:11:33 2021 +0100
patch 8.2.2662: there is no way to avoid some escape sequences
Problem: There is no way to avoid some escape sequences.
Solution: Suppress escape sequences when the --not-a-term argument is used.
(Gary Johnson)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 27 Mar 2021 12:15:04 +0100 |
parents | a77ea73f4db5 |
children | bebc295010b8 |
line wrap: on
line diff
--- a/src/os_unix.c +++ b/src/os_unix.c @@ -3343,7 +3343,7 @@ exit_scroll(void) else out_char('\n'); } - else + else if (!is_not_a_term()) { restore_cterm_colors(); // get original colors back msg_clr_eos_force(); // clear the rest of the display @@ -3370,9 +3370,12 @@ mch_exit(int r) { settmode(TMODE_COOK); #ifdef FEAT_TITLE - // restore xterm title and icon name - mch_restore_title(SAVE_RESTORE_BOTH); - term_pop_title(SAVE_RESTORE_BOTH); + if (!is_not_a_term()) + { + // restore xterm title and icon name + mch_restore_title(SAVE_RESTORE_BOTH); + term_pop_title(SAVE_RESTORE_BOTH); + } #endif /* * When t_ti is not empty but it doesn't cause swapping terminal