Under the metacity
window manager, fullscreen display should work with the standard shortcut defined as you describe in your question, but if you have anything other than "None" selected under System -> Preferences -> Appearance -> Visual Effects, you'll get the compiz
window manager. I couldn't find a way to make the full screen shortcut work there either.
You could use the wmctrl
utility to send a manual request for full screen mode.
wmctrl -r gvim add,fullscreen
And to revert:
wmctrl -r gvim remove,fullscreen
This works from within Vim as well, so you can map e.g. F11 to toggle full screen mode:
map <silent> <F11>
\ :call system("wmctrl -ir " . v:windowid . " -b toggle,fullscreen")<CR>
To get the complete fullscreen effect, you can hide tool and menu bar:
set guioptions-=T guioptions-=m
I personally wouldn't miss them but if you do prefer to have them in non-fullscreen, you'd probably best handle the toggling inside a function. (Check the edit history for an example.)
Finally a default setting you may have tweaked as you speak of a bottom pane is 'laststatus'
. Reset it to not show the status line when there is only one window:
set laststatus&
Or preferably find where it's set to non-default in your .vimrc
and remove it there.
1You could also write this instead of
ToggleFullscreen
:map <silent> <F11> :call system("wmctrl -ir " . v:windowid . " -b toggle,fullscreen")<CR>
– Daan Bakker – 2013-03-03T20:48:06.187Much better! Replaced the function with your mapping. – peth – 2013-03-07T23:39:57.473