A.J.Mechelynck wrote:
The portable way to maximize gvim at startup (well, with maybe at times
a one-character-cell rounding error in the size of the Vim screen) is
if has("gui_running")
set lines=9999 columns=9999
endif
The above (which is in my .vimrc) used to work for me on Windows, and
still works for me now that I'm on SuSE Linux.
Like the 'guifont' setting (and maybe others), 'lines' and 'columns',
when set in the vimrc, are "remembered" by gvim, and applied at GUI
startup.
Yes, except for the help for columns:
'columns' 'co' number (default 80 or terminal width)
global
{not in Vi}
Number of columns of the screen. Normally this is set by the terminal
initialization and does not have to be set by hand. Also see
|posix-screen-size|.
When Vim is running in the GUI or in a resizable window, setting this
option will cause the window size to be changed. When you only want
to use the size for the GUI, put the command in your |gvimrc| file.
When you set this option and Vim is unable to change the physical
number of columns of the display, the display may be messed up.
Minimum value is 12, maximum value is 10000.
It's the part about messing up the display that concerns me. I have
tried this on other systems and sometimes it works and other times it
creates a window very much larger than the screen. Why it's there a
command to simply maximize the window?
--
Just my 0.00000002 million dollars worth,
Shawn
"For the things we have to learn before we can do them, we learn by
doing them."
Aristotle