PGTS G. Patterson.   T/A PGTS ABN: 99885392845

point Site Navigation

point Other Blog Threads



  Valid HTML 4.01 Transitional

   Give Windows The Boot!
   And Say Goodbye To Viruses!

   Ubuntu

   If you own a netbook/laptop~
   Download Ubuntu Netbook!






PGTS Humble Blog

Thread: Tips/Tricks For Programming etc

Author Image Gerry Patterson. The world's most humble blogger
Gort! Klaatu barada nikto -- Helen Benson, The Day The Earth Stood Still

Set Default Font For Gvim:


Chronogical Blog Entries:



Date: Wed, 11 Jun 2025 15:25:12 +1000

Setting the default font for Gvim

After installing some new 4K screeas I found the fonts in Gvim a little too small for my steadily aging eyes. I knew how to select another font. But how could I put my choice into the .gvimrc settings file and make it permanent?

There was a handy link here:
https://askubuntu.com/questions/3531/how-to-save-font-choice-in-gvim

  1. Set the new font with the GUI [in Gvim]:
    Edit->Select Font
  2. Enter this command:
    :set gfn?
  3. Copy the string e.g.
    guifont=Monospace 14
  4. Edit [or create] ~/.gvimrc and add the line:
    set gfn=Monospace\ 14

Note: Must escape spaces (as above)

This also works for the Windows version of Gvim. [Note: Save the font setting in %userprofile%\_vimrc] ... Font names are a little more funky in Windows, however the interface is consistent.



Other Blog Posts In This Thread:

Copyright     2025, Gerry Patterson. All Rights Reserved.