Patch 8.0.1642
Problem: Running Vim in terminal fails with two windows.
Solution: Pass the number of rows to RunVimInTerminal().
Files: src/testdir/screendump.vim, src/testdir/test_terminal.vim
*** ../vim-8.0.1641/src/testdir/screendump.vim 2018-03-25 18:19:47.221066088
+0200
--- src/testdir/screendump.vim 2018-03-25 18:53:11.269828661 +0200
***************
*** 47,57 ****
set t_Co=256 background=light
hi Normal ctermfg=NONE ctermbg=NONE
let cmd = GetVimCommandClean()
" Add -v to have gvim run in the terminal (if possible)
let cmd .= ' -v ' . a:arguments
! let buf = term_start(cmd, {'curwin': 1, 'term_rows': 20, 'term_cols': 75})
! call assert_equal([20, 75], term_getsize(buf))
return buf
endfunc
--- 47,63 ----
set t_Co=256 background=light
hi Normal ctermfg=NONE ctermbg=NONE
+ " Make the window 20 lines high, unless told otherwise.
+ let rows = 20
+ if has_key(a:options, 'rows')
+ let rows = a:options['rows']
+ endif
+
let cmd = GetVimCommandClean()
" Add -v to have gvim run in the terminal (if possible)
let cmd .= ' -v ' . a:arguments
! let buf = term_start(cmd, {'curwin': 1, 'term_rows': rows, 'term_cols': 75})
! call assert_equal([rows, 75], term_getsize(buf))
return buf
endfunc
*** ../vim-8.0.1641/src/testdir/test_terminal.vim 2018-03-25
18:19:47.221066088 +0200
--- src/testdir/test_terminal.vim 2018-03-25 18:50:30.942772173 +0200
***************
*** 1064,1070 ****
\ 'redraw',
\ "set t_ts=",
\ ], 'Xscript')
! let buf = RunVimInTerminal('-S Xscript', {})
call WaitFor({-> expand('%:t') =='Xtextfile'})
call assert_equal(textfile_winid, win_getid())
--- 1064,1070 ----
\ 'redraw',
\ "set t_ts=",
\ ], 'Xscript')
! let buf = RunVimInTerminal('-S Xscript', {'rows': 10})
call WaitFor({-> expand('%:t') =='Xtextfile'})
call assert_equal(textfile_winid, win_getid())
*** ../vim-8.0.1641/src/version.c 2018-03-25 18:19:47.221066088 +0200
--- src/version.c 2018-03-25 18:52:41.258004393 +0200
***************
*** 768,769 ****
--- 768,771 ----
{ /* Add new patch number below this line */
+ /**/
+ 1642,
/**/
--
hundred-and-one symptoms of being an internet addict:
57. You begin to wonder how on earth your service provider is allowed to call
200 hours per month "unlimited."
/// Bram Moolenaar -- [email protected] -- 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 ///
--
--
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].
For more options, visit https://groups.google.com/d/optout.