Patch 8.2.2655
Problem: The -w command line argument doesn't work.
Solution: Don't set 'window' when set with the -w argument. (closes #8011)
Files: src/term.c, src/testdir/test_startup.vim
*** ../vim-8.2.2654/src/term.c 2021-03-22 16:19:37.529354296 +0100
--- src/term.c 2021-03-26 14:10:52.638845793 +0100
***************
*** 3365,3372 ****
ui_new_shellsize();
if (old_Rows != Rows)
{
! // if 'window' uses the whole screen, keep it using that
! if (p_window == old_Rows - 1 || old_Rows == 0)
p_window = Rows - 1;
old_Rows = Rows;
shell_new_rows(); // update window sizes
--- 3365,3373 ----
ui_new_shellsize();
if (old_Rows != Rows)
{
! // If 'window' uses the whole screen, keep it using that.
! // Don't change it when set with "-w size" on the command line.
! if (p_window == old_Rows - 1 || (old_Rows == 0 && p_window == 0))
p_window = Rows - 1;
old_Rows = Rows;
shell_new_rows(); // update window sizes
*** ../vim-8.2.2654/src/testdir/test_startup.vim 2021-03-20
22:16:52.961362692 +0100
--- src/testdir/test_startup.vim 2021-03-26 14:10:25.902919011 +0100
***************
*** 1045,1050 ****
--- 1045,1051 ----
func Test_w_arg()
" Can't catch the output of gvim.
CheckNotGui
+
call writefile(["iVim Editor\<Esc>:q!\<CR>"], 'Xscriptin', 'b')
if RunVim([], [], '-s Xscriptin -w Xscriptout')
call assert_equal(["iVim Editor\e:q!\r"], readfile('Xscriptout'))
***************
*** 1060,1065 ****
--- 1061,1074 ----
call assert_equal("Cannot open for script output: \"Xdir\"\n", m)
call delete("Xdir", 'rf')
endif
+
+ " A number argument sets the 'window' option
+ call writefile(["iwindow \<C-R>=&window\<CR>\<Esc>:wq! Xresult\<CR>"],
'Xscriptin', 'b')
+ if RunVim([], [], '-s Xscriptin -w 17')
+ call assert_equal(["window 17"], readfile('Xresult'))
+ call delete('Xresult')
+ endif
+ call delete('Xscriptin')
endfunc
" Test for the "-s scriptin" argument
*** ../vim-8.2.2654/src/version.c 2021-03-26 13:33:59.556825543 +0100
--- src/version.c 2021-03-26 14:07:29.359402661 +0100
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 2655,
/**/
--
How To Keep A Healthy Level Of Insanity:
12. Sing along at the opera.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/202103261314.12QDEjn2314695%40masaka.moolenaar.net.