1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 05:07:35 +00:00

LibLine+Userland: Make suggestion offsets per-suggestion

This allows the user to modify different parts of the input with
different suggestions.
This commit is contained in:
Ali Mohammad Pur 2022-02-28 17:28:47 +03:30 committed by Andreas Kling
parent 1fcef99ff7
commit 118590325a
6 changed files with 79 additions and 51 deletions

View file

@ -221,7 +221,7 @@ public:
// +-|- static offset: the suggestions start here
// +- invariant offset: the suggestions do not change up to here
//
void suggest(size_t invariant_offset = 0, size_t static_offset = 0, Span::Mode offset_mode = Span::ByteOriented) const;
void transform_suggestion_offsets(size_t& invariant_offset, size_t& static_offset, Span::Mode offset_mode = Span::ByteOriented) const;
const struct termios& termios() const { return m_termios; }
const struct termios& default_termios() const { return m_default_termios; }