I noticed when I sat down to do some work on my MacBook today that at some point recently something had gotten screwed up with respect to my .gvimrc
settings: when I launched MacVim, everything seemed normal except that my window was very small (approximately the default size). Curious, I tried verbose set columns?
which told me "180, last set from ~/.gvimrc" even though the window was obviously not 180 columns wide. set columns=180
restored the window to the expected width.
After the usual debugging and bisection of my RC files, I noticed something unusual. I'm not sure if this is related to my column sizes not applying or not, either way it's curious and I can't figure it out.
If I run: mvim -u NONE -c "set columns=100"
, I get a window like this:
If I run exactly the same command again, I get this:
verbose set co?
reports 100 and 66, respectively, in both cases saying "last set from -c argument." Repeating the launch command causes the window state to alternate.
I've tried nuking .viminfo
between runs; it has no effect.
I'm using MacVim snapshot 74 now, although I was on an earlier version when this started happening and upgraded to see if it was just a versioning thing. I'm on 10.10.3, and it's possible that this behavior is due to a MacVim-specific bug that has surfaced as a result of the OS update (which only happened recently). However if I install MacVim on my wife's laptop (running the same OS version) the behavior does not reproduce.
I'm at a loss. What on earth could be causing this behavior?
EDIT: After continued debugging, I've noticed it seems to only reproduce this way if I have an external monitor connected to the laptop. This leads me to believe it's some kind of bug.