Re: 'nowrapscan' breaks searching within fold

2013-01-14 Fir de Conversatie Ingo Karkat
On 12-Jan-13 08:36:38 +0900, Ben Fritz wrote: > On Friday, January 11, 2013 3:24:24 PM UTC-6, Bram Moolenaar wrote: >> Christian Brabandt wrote: >> >>> This means, the search starts actually after the fold. Because >>> wrapscan >> >>> applies, Vim will start searching from the beginning of the fil

Re: 'nowrapscan' breaks searching within fold

2013-01-11 Fir de Conversatie Ben Fritz
On Friday, January 11, 2013 3:24:24 PM UTC-6, Bram Moolenaar wrote: > Christian Brabandt wrote: > > > This means, the search starts actually after the fold. Because wrapscan > > > applies, Vim will start searching from the beginning of the file again > > > and find the match and open the fold.

Re: 'nowrapscan' breaks searching within fold

2013-01-11 Fir de Conversatie Bram Moolenaar
Christian Brabandt wrote: > On Mi, 09 Jan 2013, Ben Fritz wrote: > > > This seems to be related to the cursor being within the fold. > > Yes, the source code says this: > > /* If the cursor is in a closed fold, don't find another match in the same > * fold. */ > if (dirc == '/') >

Re: 'nowrapscan' breaks searching within fold

2013-01-09 Fir de Conversatie Christian Brabandt
Hi Ben! On Mi, 09 Jan 2013, Ben Fritz wrote: > This seems to be related to the cursor being within the fold. Yes, the source code says this: /* If the cursor is in a closed fold, don't find another match in the same * fold. */ if (dirc == '/') { if (hasFolding(pos.lnum,

Re: 'nowrapscan' breaks searching within fold

2013-01-09 Fir de Conversatie Ben Fritz
On Wednesday, January 9, 2013 12:05:13 PM UTC-6, Wiktor Ruben wrote: > I use Vim 7.3.715. Let's create sample fold: > > > > vim -u NONE -N > > > > :set foldmethod=marker > > i > > {{{1 > > foo bar zaz > > foo bar zazgg0za > > > > Let's try search for 'foo': '/foo'. Fold will open and c

'nowrapscan' breaks searching within fold

2013-01-09 Fir de Conversatie Wiktor Ruben
I use Vim 7.3.715. Let's create sample fold: vim -u NONE -N :set foldmethod=marker i {{{1 foo bar zaz foo bar zazgg0za Let's try search for 'foo': '/foo'. Fold will open and cursor will be placed at the beginning of 'foo'. Great. Now, let's go back where we started with 'gg0', close the fold wit