" NrrwRgn.vim - Narrow Region plugin for Vim " ------------------------------------------------------------- " Version: 0.26 " Maintainer: Christian Brabandt " Last Change: Mon, 02 Jan 2012 21:33:50 +0100 " " Script: http://www.vim.org/scripts/script.php?script_id=3075 " Copyright: (c) 2009, 2010 by Christian Brabandt " The VIM LICENSE applies to histwin.vim " (see |copyright|) except use "NrrwRgn.vim" " instead of "Vim". " No warranty, express or implied. " *** *** Use At-Your-Own-Risk! *** *** " GetLatestVimScripts: 3075 26 :AutoInstall: NrrwRgn.vim " " Init: {{{1 let s:cpo= &cpo if exists("g:loaded_nrrw_rgn") || &cp finish endif set cpo&vim let g:loaded_nrrw_rgn = 1 " Debug Setting let s:debug=0 if s:debug call nrrwrgn#Debug(1) endif " ---------------------------------------------------------------------------- " Public Interface: {{{1 " Define the Command aliases "{{{2 com! -range NRPrepare :,NRP com! -range NarrowRegion :,NR com! NRMulti :NRM com! NarrowWindow :NW " Define the actual Commands "{{{2 com! -range NR :, call nrrwrgn#NrrwRgn() com! -range NRP :exe ":" . . ',' . . "call nrrwrgn#Prepare()" com! NRV :call nrrwrgn#VisualNrrwRgn(visualmode()) com! NUD :call nrrwrgn#UnifiedDiff() com! NW :exe ":" . line('w0') . ',' . line('w$') . "call nrrwrgn#NrrwRgn()" com! NRM :call nrrwrgn#NrrwRgnDoPrepare() " Define the Mapping: "{{{2 if !hasmapto('NrrwrgnDo') xmap nr NrrwrgnDo endif xnoremap