(improved link; direct to toggle window layout plugin) |
(fix DrChip changed URL + minor manual clean) |
||
Line 3: | Line 3: | ||
|previous=861 |
|previous=861 |
||
|next=863 |
|next=863 |
||
− | |created= |
+ | |created=2005 |
|complexity=intermediate |
|complexity=intermediate |
||
|author=Charles E. Campbell, Jr. |
|author=Charles E. Campbell, Jr. |
||
Line 12: | Line 12: | ||
}} |
}} |
||
Suppose you have three windows in a "horizontal list", like this: |
Suppose you have three windows in a "horizontal list", like this: |
||
− | |||
<pre> |
<pre> |
||
+ | Window1|Window2|Window3 |
||
− | W|W|W |
||
</pre> |
</pre> |
||
Entering the command: |
Entering the command: |
||
− | |||
<pre> |
<pre> |
||
:windo wincmd K |
:windo wincmd K |
||
Line 24: | Line 22: | ||
will change the windows to a "vertical list", like this: |
will change the windows to a "vertical list", like this: |
||
− | |||
<pre> |
<pre> |
||
+ | Window1 |
||
− | W |
||
+ | Window2 |
||
− | W |
||
+ | Window3 |
||
− | W |
||
</pre> |
</pre> |
||
Starting with a "vertical list", entering the command: |
Starting with a "vertical list", entering the command: |
||
− | |||
<pre> |
<pre> |
||
:windo wincmd H |
:windo wincmd H |
||
Line 40: | Line 36: | ||
==Related plugins== |
==Related plugins== |
||
− | * twl.vim implements :TWL (toggle window layout) which detects which type of window layout you currently have (vertical |
+ | *[http://drchip.0sites.net/astronaut/vim/index.html#TWL twl.vim] implements <tt>:TWL</tt> (toggle window layout) which detects which type of window layout you currently have (vertical or horizontal), and applies the correct command to toggle the layout. |
==Comments== |
==Comments== |
Revision as of 07:45, 11 August 2011
Tip 862 Printable Monobook Previous Next
created 2005 · complexity intermediate · author Charles E. Campbell, Jr. · version 6.0
Suppose you have three windows in a "horizontal list", like this:
Window1|Window2|Window3
Entering the command:
:windo wincmd K
will change the windows to a "vertical list", like this:
Window1 Window2 Window3
Starting with a "vertical list", entering the command:
:windo wincmd H
will change the windows to a "horizontal list".
Related plugins
- twl.vim implements :TWL (toggle window layout) which detects which type of window layout you currently have (vertical or horizontal), and applies the correct command to toggle the layout.