News for hackers. Stuff that matters.
Re:Two weeks with Vim by gurraman on Monday November 15, 2010 @08:26PM (#1908681)
I too like to have code from multiple logical sections of my projects visible on the same screen at times.

Splitting windows in vim works nicely for this purpose.

Re:Two weeks with Vim by donaq on Monday November 15, 2010 @08:38PM (#1908722)
I can see how that would be useful, but I have a question. If you do edits in both windows, how do you save them? Do you just save in one window and reload the other?
Re:Two weeks with Vim by Periodic on Monday November 15, 2010 @09:07PM (#1908771)
In vim, when you have the same file open in different windows any changes immediately appear in the other window. They are the same buffer, there are just two windows to it.

You can see this by opening a file, and hitting "<Ctrl-W> <Ctrl-S>" to split the window. Do some editing and you'll see it in both places. ":ls" will show only one buffer. And if you have display of the buffer state visible, when you ":w" all the windows will update to say they were saved.

Re:Two weeks with Vim by donaq on Tuesday November 16, 2010 @01:30AM (#1909293)
Wow, I did not know that. I've always just assumed they'd be different buffers. I'll probably be using this a lot in future. Thanks!