aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vim.dot.link/plugin/session_workarounds.vim26
-rw-r--r--vim.dot.link/plugin/window_title.vim10
2 files changed, 18 insertions, 18 deletions
diff --git a/vim.dot.link/plugin/session_workarounds.vim b/vim.dot.link/plugin/session_workarounds.vim
index af11f3d..3b43b5b 100644
--- a/vim.dot.link/plugin/session_workarounds.vim
+++ b/vim.dot.link/plugin/session_workarounds.vim
@@ -58,25 +58,25 @@ endfunction
" https://vi.stackexchange.com/questions/8926/is-it-possible-to-obtain-the-displayable-area-width-and-height-of-current-buffe
"let lines_initial=&l:lines
function FixWindowHeights()
- " Set the maximum available height
- set lines=999
+ " Set the maximum available height
+ set lines=999
- " Set the lines depending on the LINES environment variable
- " or through tput.
- "
- " This is not always inherited by vim:
- " https://github.com/vim/vim/issues/12160
- if $LINES != ""
- execute ':set lines=' . $LINES
- else
- let available_lines = system('tput lines')
- execute ':set lines=' . available_lines
+ " Set the lines depending on the LINES environment variable
+ " or through tput.
+ "
+ " This is not always inherited by vim:
+ " https://github.com/vim/vim/issues/12160
+ if $LINES != ""
+ execute ':set lines=' . $LINES
+ else
+ let available_lines = system('tput lines')
+ execute ':set lines=' . available_lines
" Old, and not working approach that tries to reuse the initial height
"else
" execute ':set lines=' . lines_initial
" set lines=999
" execute ':set lines=' . winheight(0) - 3
- endif
+ endif
endfunction
" Restore all window sizes
diff --git a/vim.dot.link/plugin/window_title.vim b/vim.dot.link/plugin/window_title.vim
index bb82977..b602af1 100644
--- a/vim.dot.link/plugin/window_title.vim
+++ b/vim.dot.link/plugin/window_title.vim
@@ -18,10 +18,10 @@ augroup END
"
" Thanks to http://stackoverflow.com/questions/1673649/vimrc-action-onclose
function! ResetTitle(title)
- " disable vim's ability to set the title
- exec "set title t_ts='' t_fs=''"
+ " disable vim's ability to set the title
+ exec "set title t_ts='' t_fs=''"
- " and restore it
- "exec ":!echo -e '\033kbash\033\\'\<CR>"
- exec ":!xtitle -q " a:title
+ " and restore it
+ "exec ":!echo -e '\033kbash\033\\'\<CR>"
+ exec ":!xtitle -q " a:title
endfunction