1
1
mirror of https://github.com/wez/wezterm.git synced 2024-12-25 14:22:37 +03:00
wezterm/termwiz/src/surface
Mikko Perttunen 12a6b8df84 termwiz: surface: Fix cursor movement in DiffState
DiffState keeps track of a virtual cursor in order to skip emitting
cursor location changes when a previous text change has already moved
the cursor to the desired position. However, currently the code always
advances the cursor by 1 column for each added text change regardless
of the width of the text.

Fix behavior by advancing the cursor by the width of the text.
To avoid having to add a new variable, make 'self.cursor' contain
the cursor position for the next cell instead of the current cell.

In addition, add a test verifying the behavior.
2024-01-23 06:42:13 -07:00
..
line termwiz: surface: Fix cell diffing in presence of wide cells 2024-01-23 06:42:13 -07:00
change.rs ssh: use double height text for host key failure case 2023-07-06 12:53:05 -07:00
mod.rs termwiz: surface: Fix cursor movement in DiffState 2024-01-23 06:42:13 -07:00