1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 13:07:46 +00:00

LibLine: Avoid refreshing the entire line when inserting at the end

This patchset allows the editor to avoid redrawing the entire line when
the changes cause no unrecoverable style updates, and are at the end of
the line (this applies to most normal typing situations).
Cases that this does not resolve:
- When the cursor is not at the end of the buffer
- When a display refresh changes the styles on the already-drawn parts
  of the line
- When the prompt has not yet been drawn, or has somehow changed

Fixes #5296.
This commit is contained in:
AnotherTest 2021-02-20 21:33:13 +03:30 committed by Andreas Kling
parent 101c6b01ed
commit 074e2ffdfd
5 changed files with 151 additions and 41 deletions

View file

@ -238,6 +238,10 @@
#cmakedefine01 LEXER_DEBUG
#endif
#ifndef LINE_EDITOR_DEBUG
#cmakedefine01 LINE_EDITOR_DEBUG
#endif
#ifndef LOG_DEBUG
#cmakedefine01 LOG_DEBUG
#endif