version 1.46, 2017/08/06 04:39:45 |
version 1.47, 2018/07/11 12:21:37 |
|
|
/* |
/* |
* Incremental Search. |
* Incremental Search. |
* dir is used as the initial direction to search. |
* dir is used as the initial direction to search. |
|
* ^M exit from Isearch, set mark |
* ^S switch direction to forward |
* ^S switch direction to forward |
* ^R switch direction to reverse |
* ^R switch direction to reverse |
* ^Q quote next character (allows searching for ^N etc.) |
* ^Q quote next character (allows searching for ^N etc.) |
* <ESC> exit from Isearch |
* <ESC> exit from Isearch, set mark |
* <DEL> undoes last character typed. (tricky job to do this correctly). |
* <DEL> undoes last character typed. (tricky job to do this correctly). |
* other ^ exit search, don't set mark |
* other ^ exit search, don't set mark |
* else accumulate into search string |
* else accumulate into search string |
|
|
*/ |
*/ |
if (ttwait(300) == FALSE) |
if (ttwait(300) == FALSE) |
ungetkey(c); |
ungetkey(c); |
|
/* FALLTHRU */ |
|
case CCHR('M'): |
srch_lastdir = dir; |
srch_lastdir = dir; |
curwp->w_markp = clp; |
curwp->w_markp = clp; |
curwp->w_marko = cbo; |
curwp->w_marko = cbo; |
|
|
case CCHR('\\'): |
case CCHR('\\'): |
case CCHR('Q'): |
case CCHR('Q'): |
c = (char)getkey(FALSE); |
c = (char)getkey(FALSE); |
goto addchar; |
|
case CCHR('M'): |
|
c = CCHR('J'); |
|
goto addchar; |
goto addchar; |
default: |
default: |
if (ISCTRL(c)) { |
if (ISCTRL(c)) { |