diff options
author | Christian Duerr <contact@christianduerr.com> | 2021-04-29 17:06:44 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-29 17:06:44 +0000 |
commit | 4d982894a6859b6d4eeb967ec6dbbf5965c79165 (patch) | |
tree | c9ccb721497b6f4d6f26002b9b5e76babab189ac /alacritty_terminal/src/term/cell.rs | |
parent | 11cbc439c8785ed937125e0ba2a60ef470564a5e (diff) | |
download | alacritty-4d982894a6859b6d4eeb967ec6dbbf5965c79165.tar.gz alacritty-4d982894a6859b6d4eeb967ec6dbbf5965c79165.zip |
Fix replacement of fullwidth characters
Fixes #3726.
Diffstat (limited to 'alacritty_terminal/src/term/cell.rs')
-rw-r--r-- | alacritty_terminal/src/term/cell.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/alacritty_terminal/src/term/cell.rs b/alacritty_terminal/src/term/cell.rs index 255cbce7..64de5492 100644 --- a/alacritty_terminal/src/term/cell.rs +++ b/alacritty_terminal/src/term/cell.rs @@ -99,6 +99,14 @@ impl Cell { self.extra = None; } } + + /// Remove all wide char data from a cell. + #[inline(never)] + pub fn clear_wide(&mut self) { + self.flags.remove(Flags::WIDE_CHAR); + self.drop_extra(); + self.c = ' '; + } } impl GridCell for Cell { |