Set some window options to their deafults

This commit is contained in:
Ben Jackson 2020-02-16 22:30:55 +00:00
commit 926029e343
3 changed files with 11 additions and 0 deletions

View file

@ -42,6 +42,7 @@ class StackTraceView( object ):
# FIXME: Remove all usage of "Windown" and just use buffers to prevent all
# the bugs around the window being closed.
self._win = vim.current.window
utils.SetUpUIWindow( self._win )
vim.command( 'nnoremap <buffer> <CR> :call vimspector#GoToFrame()<CR>' )

View file

@ -126,6 +126,13 @@ def SetUpPromptBuffer( buf, name, prompt, callback, hidden=False ):
Escape( callback ) ) )
def SetUpUIWindow( win ):
win.options[ 'wrap' ] = False
win.options[ 'number' ] = False
win.options[ 'signcolumn' ] = 'no'
win.options[ 'spell' ] = False
win.options[ 'list' ] = False
@contextlib.contextmanager
def ModifiableScratchBuffer( buf ):

View file

@ -65,6 +65,9 @@ class VariablesView( object ):
'Expression: ',
'vimspector#AddWatchPrompt' )
utils.SetUpUIWindow( self._vars.win )
utils.SetUpUIWindow( self._watch.win )
has_balloon = int( vim.eval( "has( 'balloon_eval' )" ) )
has_balloon_term = int( vim.eval( "has( 'balloon_eval_term' )" ) )