Move wrapping detection out of the single character insertion case #186
Labels
A-Display
Area: Correctness of the display output and additional features needed there
A-Multiline
Area: Support for multiline editing (Validation and interaction with `A-Display`)
Currently wrapping detection is only performed when handling the insert of a single character...
reedline/src/engine.rs
Lines 813 to 828 in 75d9b4b
... but this is wrong as the line's content could also overflow on other operations (e.g. using the paste operations or undo) resulting in the requirement to move the cursor.
Thus we either do such a detection explicitly on inserting operations or move the check and cursor position update into the painter and do it there in the flow of the output.
#176 relates to other technical issues with the current implementation. #180 improved some of the details, but insertions in the middle of the line that might shift the cursor are not fully covered yet.
The text was updated successfully, but these errors were encountered: