News for hackers. Stuff that matters.
Re:Use Vim Like A Pro by hesitz on Sunday October 31, 2010 @06:06PM (#1854486)
You can make use of the foldcolumn. The fold column is an optionally visible column that can be put between line numbers and text. It is generally used to show markers to indicate level of folding, if any. If you want to use it to create separation between line numbers and text, but don't want to see the folding markers, just set the foreground color of the fold column to be same as the background color. So something like this:

:set foldcolumn=3 (or 4 or 5 or what4ever. . . )

:hi FoldColumn guifg=black guibg=black

That should do it.

Re:Use Vim Like A Pro by klochner on Sunday October 31, 2010 @08:16PM (#1854830)
That helps if you don't have numbers, but I'm getting the padding left of my line numbers.

Is there a way to swap the foldcolumn to the left of line numbers?

Re:Use Vim Like A Pro by hesitz on Sunday October 31, 2010 @10:37PM (#1855157)
Very sorry, my mistake. I thought I had checked and confirm that it did appear to the right and I must have looked too quickly. No, I don't think there is a way to swap those columns. (At least not through Vim 7.2, Vim 7.3 introduced relative line numbering and maybe it has a teak in addition to that -- but I doubt it.) It's not too hard to adjust line indenting so it defaults to minimum that is greater than 1, say 2 or 3, but that would be sort of an ugly hack, inserting blank spaces into your document for mere purpose of viewing more space between line column and text.