sponsor Vim development Vim logo Vim Book Ad

navigation_enhancer.vim : When moving between windows, uses history not cursor position to select target.

 script karma  Rating 4/1, Downloaded by 151    Comments, bugs, improvements  Vim wiki

created by
joey twiddle
 
script type
utility
 
description
Navigation Enhancer v2.0 by joey.neuralyte.org

aka Retrace Your Steps

When moving the cursor between windows, given a choice of target windows,
Vim normally uses the *cursor position* to choose the destination window.

However I think a more intuitive approach when there may be more than one
potential target window is to pick the one which was *used most recently*.

Or perhaps more accurately, we want the window that we *last entered from, in
that direction*.

So now if I casually move between windows in one direction, and then in the
opposite direction, I should always return to the window I started from!
 
install details
drop in plugin/

Check the mappings in the script to check that it intercepts the keys you use for window navigation.  (If C-W k or C-W-Up then fine.)
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
navigation_enhancer.vim 2.0 2012-10-24 7.0 joey twiddle Initial upload
ip used for rating: 54.89.106.125

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
SourceForge.net Logo