Fix #6671: Check search bounds and bind missing control characters in i-search modes

This fixes #6671 and adds the following new functionality in search mode:

      ^L clears the display
      ^N and ^P iterate through the next or previous result
      ^G and ESC-ESC cancel search mode
      ^W erases the previous word to whitespace