diff options
author | Christian Duerr <contact@christianduerr.com> | 2023-01-15 22:53:41 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-15 22:53:41 +0000 |
commit | 5a3280e8e0184c94e7a3f0a89676090d0694408d (patch) | |
tree | a5a0d1c38c0bd9ad750838d4373d9792e4377303 /alacritty_terminal/src/term/mod.rs | |
parent | bcd6d0d981fd192f21a2f5142f421f4aa1de1648 (diff) | |
download | alacritty-5a3280e8e0184c94e7a3f0a89676090d0694408d.tar.gz alacritty-5a3280e8e0184c94e7a3f0a89676090d0694408d.zip |
Preserve last column with erase in line right
When the erase in line escape sequence with a parameter of 0 (right) is
passed while the wrapline flag is already set, it will no longer clear
the last column and instead ignore the operation.
The behavior of `\e[1K` and `\e[2K` is unchanged and both will clear the
entire first line without clearing the wrapline flag.
Closes #6159.
Diffstat (limited to 'alacritty_terminal/src/term/mod.rs')
-rw-r--r-- | alacritty_terminal/src/term/mod.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/alacritty_terminal/src/term/mod.rs b/alacritty_terminal/src/term/mod.rs index 98f76d52..e41120da 100644 --- a/alacritty_terminal/src/term/mod.rs +++ b/alacritty_terminal/src/term/mod.rs @@ -1458,6 +1458,7 @@ impl<T: EventListener> Handler for Term<T> { let point = cursor.point; let (left, right) = match mode { + ansi::LineClearMode::Right if cursor.input_needs_wrap => return, ansi::LineClearMode::Right => (point.column, Column(self.columns())), ansi::LineClearMode::Left => (Column(0), point.column + 1), ansi::LineClearMode::All => (Column(0), Column(self.columns())), |