diff options
author | Jesse Luehrs <doy@tozt.net> | 2019-11-29 04:40:39 -0500 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2019-12-05 12:54:34 -0500 |
commit | 3fbc74f513a5a691dd99705598c3023f3b8bc173 (patch) | |
tree | 86f0ea6af9604bb2befa8798fe683daa50be76f2 /src | |
parent | dc62fd174f6c5887e958b9b9bc8305ddd7c428a8 (diff) | |
download | vt100-rust-3fbc74f513a5a691dd99705598c3023f3b8bc173.tar.gz vt100-rust-3fbc74f513a5a691dd99705598c3023f3b8bc173.zip |
handle wide char wrapping correctly
wrapping a wide char should set the wrapping state of the line even if
it wrapped before the last column
Diffstat (limited to 'src')
-rw-r--r-- | src/row.rs | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -167,7 +167,9 @@ impl Row { if pos != prev_pos { if !wrapping || prev_pos.row + 1 != pos.row - || prev_pos.col != self.cols() + || prev_pos.col + < self.cols() + - if cell.is_wide() { 1 } else { 0 } || pos.col != 0 { crate::term::MoveFromTo::new(prev_pos, pos) @@ -260,7 +262,9 @@ impl Row { if pos != prev_pos { if !wrapping || prev_pos.row + 1 != pos.row - || prev_pos.col != self.cols() + || prev_pos.col + < self.cols() + - if cell.is_wide() { 1 } else { 0 } || pos.col != 0 { crate::term::MoveFromTo::new(prev_pos, pos) |