On 04:10 Tue 15 Feb     , Trans wrote:
> 
> Thomas Kirchner wrote:
> > It has to be said.  Gvim :)  If you already know vi, it's the
> > only way to fly.
> 
> I use vi/vim for quick/light editing. But I don't understand how others
> use it as their main editor. And I don't say this lightly: I even
> bought a book on using vi/vim. Yet I still often hear how "wonderous"
> it is if one does.
> 
> So tell me this, how does one copy and paste without counting lines?
> Using n+yy & p (where n is some number) for a few lines is okay, but
> beyond that...

Use the 'v' familiy of commands to enter 'visual' select mode.

1. Position the cursor on the first line you wish to copy.
2. Press 'v' (for character-wise selection) or 'shift-v' (for
   line-wise selection) or 'ctrl-v' (for block-wise selection)
3. Select the text you want to copy (using the arrow keys, etc.)
4. Press 'y' to 'yank' (copy) the text, or 'x' to cut it.
5. Move the cursor to where you want to paste.
6. Press 'p' to paste after the current cursor position, or 'P' to
   paste before it.

I use the 'v' commands all the time. Unfortunately, they are unique to
vim--vanilla 'vi' has no such niceties.

That said--vim won't be for everyone. Just as emacs works well for
many people, it doesn't work well for everyone (read, "me"). So don't
feel bad if you can't wrap your thinking around vim. Just look for the
tool that fits your way of doing things.

- Jamis

-- 
Jamis Buck
jamis_buck / byu.edu
http://jamis.jamisbuck.org
------------------------------
"I am Victor of Borge. You will be assimil-nine-ed."