To: vim_dev@googlegroups.com Subject: Patch 8.2.0490 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.0490 Problem: Win32: VTP doesn't respect 'restorescreen'. Solution: Use escape codes to switch to alternate screen. (Nobuhiro Takasaki, closes #5872) Files: src/os_win32.c *** ../vim-8.2.0489/src/os_win32.c 2020-03-26 15:39:50.219238206 +0100 --- src/os_win32.c 2020-04-01 18:25:21.990700654 +0200 *************** *** 5431,5436 **** --- 5431,5439 ---- if (g_fTermcapMode) return; + if (!p_rs && USE_VTP) + vtp_printf("\033[?1049h"); + SaveConsoleBuffer(&g_cbNonTermcap); if (g_cbTermcap.IsValid) *************** *** 5530,5535 **** --- 5533,5541 ---- SetConsoleCursorPosition(g_hConOut, coord); } + if (!p_rs && USE_VTP) + vtp_printf("\033[?1049l"); + g_fTermcapMode = FALSE; } #endif // FEAT_GUI_MSWIN *** ../vim-8.2.0489/src/version.c 2020-04-01 16:34:12.555263953 +0200 --- src/version.c 2020-04-01 18:27:25.846288926 +0200 *************** *** 740,741 **** --- 740,743 ---- { /* Add new patch number below this line */ + /**/ + 490, /**/ -- ARTHUR: Go on, Bors, chop its head off. BORS: Right. Silly little bleeder. One rabbit stew coming up. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///