guifont + lines + colums

69 views
Skip to first unread message

Keyan

unread,
Oct 5, 2012, 10:59:10 AM10/5/12
to vim...@googlegroups.com
Hi,

I still have the problem that the following line

:set guifont=Menlo:h26 lines=30 columns=80

does change the font, but not the lines and columns.

Cheers,
Keyan

Bee

unread,
Oct 5, 2012, 12:28:07 PM10/5/12
to vim_mac
Do you have that line in .vimrc?
If yes, try it in .gvimrc

Works here with one exception, my laptop screen is
not large enough to display 80 columns at Menlo:h26

But this works great:

:set guifont=Menlo:h18 lines=30 columns=80

Bill

Keyan

unread,
Oct 5, 2012, 3:10:05 PM10/5/12
to vim...@googlegroups.com
Hi,

i had it in my .vimrc and in my .gvimrc. what i have send is from the command mode. the line you have posted does not work for me. i use

VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Sep 1 2012 01:05:49)
MacOS X (unix) version
Included patches: 1-604

(compiled from homebrew)

Cheers,
Keyan

Bee

unread,
Oct 5, 2012, 3:27:59 PM10/5/12
to vim_mac
Keyan wrote:
> i had it in my .vimrc and in my .gvimrc.
> what i have send is from the command mode.
> the line you have posted does not work for me. i use
>
> VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Sep 1 2012 01:05:49)
> MacOS X (unix) version
> Included patches: 1-604

Try this in .gvimrc, remove the reference to guifont

set lines=30 columns=80

Does that work?

Keyan

unread,
Oct 5, 2012, 4:11:11 PM10/5/12
to vim...@googlegroups.com
removed set guifont from .gvimrc, and I have none in the .vimrc. added set lines=30 colums=80 in the last line of my .gvimrc and it did not work, because i have set fu. if i remove this option, it works. i like to use vim in full-screen mode by default, so that is why i forgot to add that important information. sorry for that.

the initial :set command that i posted works fine in non-fullscreen mode. i use the build-in fullscreen method, not the mac os version of fullscreen, because i like to see the output (e.g. latex) on the second screen.

cheers,
Keyan

Bee

unread,
Oct 5, 2012, 4:36:48 PM10/5/12
to vim_mac
:help fullscreen
...
Note: Setting 'fullscreen' usually changes the size of the Vim
control. However, for technical reasons, 'lines' and 'columns'
will currently only be updated when Vim runs its event loop. As
a consequence, if you set 'fullscreen' and 'lines' or 'columns'
in a Vim script file, you should always set 'fullscreen' after
setting 'lines' and 'columns', else 'lines' and 'columns' will
be overwritten with the values 'fullscreen' sets after the
script has been executed and the event loop is ran again.

Also see:
:help fuoptions

Bee

unread,
Oct 5, 2012, 5:04:18 PM10/5/12
to vim_mac
PS
If I set fullscreen in a script is does not work.

In .gvimrc I set lines and columns
and set fuoptions to do not change size of vim
and this mapping to toggle fullscreen

" -------1---------2---------3---------4---------5---------6----
:set guifont=Menlo:h18 lines=30 columns=80

" Don't change size of Vim when entering fullscreen
:set fuoptions=

" Toggle fullscreen
:nmap <F12> :set fullscreen!<cr>

" -------1---------2---------3---------4---------5---------6----

:help fuoptions

Bill

Keyan

unread,
Oct 6, 2012, 5:56:12 AM10/6/12
to vim...@googlegroups.com
Hi,

thanks a lot. The set fuoptions did the trick! :)

Cheers,
Keyan
> --
> You received this message from the "vim_mac" maillist.
> Do not top-post! Type your reply below the text you are replying to.
> For more information, visit http://www.vim.org/maillist.php

Reply all
Reply to author
Forward
0 new messages