Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Setting lines and cols to 999 works only if the toolbars and menubars are there but if I remove them, it doesn't start maximized anymore. I usually have to alt+space and then hit x to maximize it. Is there a way to have this done automatically?

Here's what's in my vimrc right now:

set smartindent
set tabstop=8
set shiftwidth=4
set expandtab
set number
set guifont=Consolas\ 10
syntax on
:colo wombat
filetype on
filetype plugin indent on
set backspace=indent,eol,start
set noerrorbells
set showmatch
set softtabstop=4
set ignorecase
set smartcase
set scrolloff=3
let Tlist_Exist_OnlyWindow = 1
let Tlist_Use_Right_Window = 1
set guioptions-=L
set guioptions-=r
set guioptions-=m
set guioptions-=T
set lines=999 columns=999

map <c-j> <c-w>j
map <c-k> <c-w>k
map <c-l> <c-w>l
map <c-h> <c-w>h
nnoremap <silent> <C-N> :NERDTreeToggle<CR>
nnoremap <silent> <C-T> :Tlist<CR>

I just figured out that the :simalt ~x does exactly what I'm describing here but it doesn't work under linux. I get a command not available in this version error.

EDIT: After lots of googling, it seeems that this is a vim-gtk bug with no fix yet.

share|improve this question

1 Answer 1

with fluxbox as the windowmanager you could setup a rule which would maximize any number of gvim-instances upon creation. read man fluxbox-apps if you are using fluxbox.

a more general or windowmanager-independent approach is to use devilspie which allows you to setup some matching rules to identify windows and then apply actions onto them.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.