Next Prev Up Top Contents Index

10.12.2 Incremental searches

Press Ctrl+S to perform an incremental search (in which every character you type further refines the search). A prompt appears in the echo area, asking you to type a string to search for. As soon as you start typing, the search commences.

Consider the following example: You want to search for the word "defmacro" in a file.

  1. Select Edit > Find... or press Ctrl+S
  2. The following prompt appears in the echo area.

    I-Search:
  3. Type the letter d .
  4. The prompt in the echo area changes to

    I-Search: d

    The cursor moves to the first occurrence of "d" after its current position.

  5. Type the letter e .
  6. The prompt in the echo area changes to

    I-Search: de

    The cursor moves to the first occurrence of "de".

  7. Type the letter f .

The prompt in the echo area changes to

I-Search: def

The cursor moves to the first occurrence of "def".

This continues until you stop typing, or until the editor fails to find the string you have typed in the current buffer. If at any point this does occur, the prompt in the echo area changes to reflect this. For instance, if your file contains the word "defun" but not the word "defmacro", the prompt changes to

Failing I-Search: defm

as soon as you type m .


Common LispWorks User Guide - 14 Dec 2001

Next Prev Up Top Contents Index