> Wow! Ok. the first seems clear enough, but a little tedious for the > number of lines I have (it's delimited text, so I could always note > the line number, %, note the line number, then use that search). > > The latter seems like dark magic. I'll meditate upon it while > consulting the book of :help > > Thanks for the super speedy reply! > >> <c-c>/<bslash>%><c-r>=line("'<lt>")-1<cr>l<bslash>%<lt><c-r>=line("'>")+1<cr>l
It's only magic until you understand it :) It basically uses the control+R followed by the equals-sign to insert the evaluation of expressions to determine the lines just outside your selection: :help c_CTRL-R_= The expressions are line("'<")-1 (the number of the line before the start of the selection) and line("'>")+1 (the number of the line after the end of the selection) So it just is inserting those line numbers into the {} blocks in: \%>{start-1}l\%<{end+1}l with some escaping of things like back-slashes and less-than signs. Hope this helps pull back the mystery of the line-noise above. -tim