Module scout::person_input

source ·
Expand description

Read the input from the person using the program

The input can be:

  • New characters for the search query
  • Control sequences to move around the list
  • Control sequences to move around the prompt
  • Signals to cancel and exit
  • Signals to select a candidate from the list

All of these actions are processed and sent as events to the rest of tasks.

Moving around the list

  • You can use Up and Down keys to move through the list of candidates
  • <C-p> does the same the Up key and <C-n> as the Down key
  • Backspace will remove the character behind the cursor

Moving around the prompt

  • You can use the Left and Right keys to move the cursor in the prompt
  • <C-e> will go to the end of the prompt and <C-a> to the beginning
  • <C-u> clears the current query

Selecting a candidate and exiting the program

  • Enter will select the current candidate
  • Esc will exit the program without making a selection

Functions

Run the person’s input task