Fandom

Vim Tips Wiki

Selecting blocks of paragraphs

1,624pages on
this wiki
Add New Page
Talk0 Share

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Tip 876 Printable Monobook Previous Next

created 2005 · complexity basic · author Dane Summers · version 6.0


Here are two mappings that help copy SQL queries from gvim to other applications running under Windows.

"Select all of current paragraph.
:map <C-S-v> (V)

"Copy all of current paragraph to clipboard.
:map <C-S-v> (V)*y''

 TO DO 
Fix above:

  1. The ( and ) move by a sentence, not a paragraph.
  2. Tip should use vip to select a paragraph.
  3. Fix the key used for the mapping.

CommentsEdit

You can select a paragraph by typing vip or vap

See :help v_ip (vip = visual inner paragraph).

In general, use :help v_<whatever> for help on <whatever> in visual mode.

Or :help c_<whatever> for the command line, or :help i_<whatever> for insert mode.


Also on Fandom

Random Wiki