ISuggestionGenerator.cs 718 B

123456789101112131415
  1. namespace Terminal.Gui;
  2. /// <summary>Generates autocomplete <see cref="Suggestion"/> based on a given cursor location within a string</summary>
  3. public interface ISuggestionGenerator
  4. {
  5. /// <summary>Generates autocomplete <see cref="Suggestion"/> based on a given <paramref name="context"/></summary>
  6. IEnumerable<Suggestion> GenerateSuggestions (AutocompleteContext context);
  7. /// <summary>
  8. /// Returns <see langword="true"/> if <paramref name="rune"/> is a character that would continue autocomplete
  9. /// suggesting. Returns <see langword="false"/> if it is a 'breaking' character (i.e. terminating current word
  10. /// boundary)
  11. /// </summary>
  12. bool IsWordChar (Rune rune);
  13. }