Showing posts with label quick. Show all posts
Showing posts with label quick. Show all posts

Friday, October 30, 2009

Quick Exits

Hitting ZZ in normal mode will exit and save the current file. Hitting ZQ will exit without saving.

Wednesday, June 18, 2008

Quick Redraw

You can use z. in Vim to quickly redraw the current cursor line at the center of the window. zt redraws at the top and zb redraws at the bottom. Thanks to Nate for the tip!

Thursday, May 29, 2008

Two Copies, Same Buffer

Oftentimes I like to have two copies of the same window open in a horizontal split, so I can look at different pieces of code in the same file. Vim has a handy shortcut to quickly split the current file in a new window. Just hit ctrl-w s. A side bonus is that you don't have to save the file first unlike using :new filename.

Thanks to Nate for the tip!