1

Edit: I moved the original question to 'The docked gVim in Windows 7 jumps upon tab switch'

After struggling with my .vimrc, I am resorting to setting the font from windows registry instead, because without the guifont in .vimrc, everything works fine. The only registry mentioned I found was,

HKLM\Software\Microsoft\WindowsNT\CurrentVersion\Console\TrueTypeFont

This is for MS command line, but it was not what I was looking for. Currently gVim is set to Fixedsys by default. The search though the registry for value fixedsys returned no result. My gut feeling is that one can change it through the registry setting. Is there such registry value?

Forethinker
  • 690
  • 2
  • 8
  • 25
  • This may not be exactly what you want, but you might consider using standard vim (non-gui) in Windows. Using more high quality console replacement such as [console 2](http://sourceforge.net/projects/console/) will give you the usual VIM experience, and you should be able to use any font you like. – Fopedush Apr 16 '13 at 21:40
  • Could you please clarify the question? More specifics on what happens versus what you expect, what sequence of commands you are using to reload the file, which settings are in `vimrc` versus `gvimrc`, stuff like that. If you are not already putting your gui initialization in a separate `gvimrc`, try that first. – Bradd Szonye Apr 16 '13 at 22:33
  • @Fopedush I already use non-gui vim through `mintty`, but the advantage of gVim is `+clientserver` option. Also if you use `vimperator` with firefox, you can also edit text fields easily with `ctrl-i` shortcut. This is not possible with `vim`. – Forethinker Apr 17 '13 at 00:54
  • @BraddSzonye I clarified the question. I do not think it is the conflict with the .vimrc (mine is quite big) and I did test it thoroughly. The auto source of .vimrc and `guifont` is all it takes to trigger the behavior. – Forethinker Apr 17 '13 at 01:09
  • Thanks. A good next step would be to create a minimal `vimrc` that reproduces the problem. Does the window become undocked if you use a `vimrc` that contains nothing but a `guifont` setting? – Bradd Szonye Apr 17 '13 at 01:15
  • Also, you might have better luck asking "how to fix this?" rather than "how to set this in the registry?" in case there's a better solution, or if the problem also happens to people on non-Windows version of vim. – Bradd Szonye Apr 17 '13 at 01:17

1 Answers1

2

The font was hardcoded into the binary of gvim.exe and vim.exe. I just search and fine through the binary for 'Fixedsys'. I changed that portion to with the name of font I wanted and it was all good. Any editor will do, but I used another vim (non-gui, cygwin) in this case, because vim is very good for opening a massive file. I did not need to recompile

Forethinker
  • 690
  • 2
  • 8
  • 25
  • 1
    Did you recompile it or hack the binary? Any details you could offer to help people who want to accomplish the same thing? – Bradd Szonye Apr 17 '13 at 23:23