summaryrefslogtreecommitdiff
path: root/src/os_win32.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-04-01 18:29:10 +0200
committerBram Moolenaar <Bram@vim.org>2020-04-01 18:29:10 +0200
commit0afdcf8601792ee751984265b49fc2ca6f8ea858 (patch)
tree06797606a4501b990b5b2825b013d0dd7c08305f /src/os_win32.c
parent25b70c780a7e6063544e7f93c368fe403076f34e (diff)
downloadvim-git-0afdcf8601792ee751984265b49fc2ca6f8ea858.tar.gz
patch 8.2.0490: Win32: VTP doesn't respect 'restorescreen'v8.2.0490
Problem: Win32: VTP doesn't respect 'restorescreen'. Solution: Use escape codes to switch to alternate screen. (Nobuhiro Takasaki, closes #5872)
Diffstat (limited to 'src/os_win32.c')
-rw-r--r--src/os_win32.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/os_win32.c b/src/os_win32.c
index 1952b3636..77e43d5d3 100644
--- a/src/os_win32.c
+++ b/src/os_win32.c
@@ -5431,6 +5431,9 @@ termcap_mode_start(void)
if (g_fTermcapMode)
return;
+ if (!p_rs && USE_VTP)
+ vtp_printf("\033[?1049h");
+
SaveConsoleBuffer(&g_cbNonTermcap);
if (g_cbTermcap.IsValid)
@@ -5530,6 +5533,9 @@ termcap_mode_end(void)
SetConsoleCursorPosition(g_hConOut, coord);
}
+ if (!p_rs && USE_VTP)
+ vtp_printf("\033[?1049l");
+
g_fTermcapMode = FALSE;
}
#endif // FEAT_GUI_MSWIN