FANDOM


m (Fix link to help)
(Uploaded by JohnBot from a locally edited file)
Line 1: Line 1:
 
{{review}}
 
{{review}}
{{Tip
+
{{TipImported
 
|id=137
 
|id=137
|title=automatically wrap left and right
+
|previous=136
|created=October 14, 2001 21:15
+
|next=138
  +
|created=October 14, 2001
 
|complexity=basic
 
|complexity=basic
 
|author=Brian Medley
 
|author=Brian Medley
 
|version=5.7
 
|version=5.7
 
|rating=9/5
 
|rating=9/5
|text=
+
}}
By default, when pressing left/right cursor keys, Vim will not move to the previous/next line after reaching first/last character in the line. This can be quite annoying for new users. Fortunately this behaviour can be easily changed by putting this in your ~/.vimrc file:
+
By default, when pressing left/right cursor keys, Vim will not move to the previous/next line after reaching first/last character in the line. This can be quite annoying for new users. Fortunately this behaviour can be easily changed by putting this in your ~/.vimrc file:
   
 
<pre>
 
<pre>
Line 17: Line 17:
 
This causes the cursorkeys, as well as h and l, to wrap, when used at beginning and end of lines (the &lt;&gt; and [] differ in that &lt;&gt; are the cursorkeys used in normal and visual mode, and the [] are the cursorkeys in insert mode).
 
This causes the cursorkeys, as well as h and l, to wrap, when used at beginning and end of lines (the &lt;&gt; and [] differ in that &lt;&gt; are the cursorkeys used in normal and visual mode, and the [] are the cursorkeys in insert mode).
   
See {{help|'whichwrap'}} for more info.
+
==References==
}}
+
*{{help|'whichwrap'}}
   
== Comments ==
+
==Comments==

Revision as of 10:43, October 30, 2007

Tip 137 Printable Monobook Previous Next

created October 14, 2001 · complexity basic · author Brian Medley · version 5.7


By default, when pressing left/right cursor keys, Vim will not move to the previous/next line after reaching first/last character in the line. This can be quite annoying for new users. Fortunately this behaviour can be easily changed by putting this in your ~/.vimrc file:

set whichwrap=<,>,h,l,[,]

This causes the cursorkeys, as well as h and l, to wrap, when used at beginning and end of lines (the <> and [] differ in that <> are the cursorkeys used in normal and visual mode, and the [] are the cursorkeys in insert mode).

References

Comments

Community content is available under CC-BY-SA unless otherwise noted.