如何让Vim Gui启动时默认自动最大化并且显示空文件
1个回答
展开全部
如果你是Unix/Linux,在vimrc里添加
if has("gui_running")
" GUI is running or is about to start.
" Maximize gvim window (for an alternative on Windows, see simalt below).
set lines=999 columns=999
else
" This is console Vim.
if exists("+lines")
set lines=50
endif
if exists("+columns")
set columns=100
endif
endif
如果你是windows的GVim,在_vimrc里添加
autocmd GUIEnter * simalt ~x
至于启动之后显示空文件...你装个NerdTree,然后默认开启Vim的时候打开吧......
if has("gui_running")
" GUI is running or is about to start.
" Maximize gvim window (for an alternative on Windows, see simalt below).
set lines=999 columns=999
else
" This is console Vim.
if exists("+lines")
set lines=50
endif
if exists("+columns")
set columns=100
endif
endif
如果你是windows的GVim,在_vimrc里添加
autocmd GUIEnter * simalt ~x
至于启动之后显示空文件...你装个NerdTree,然后默认开启Vim的时候打开吧......
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询