diff options
author | Jesse Luehrs <doy@tozt.net> | 2021-12-03 12:22:48 -0500 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2021-12-03 12:22:48 -0500 |
commit | 4e4f47cb9a66eab13a40b2f7bf2477695c0ff003 (patch) | |
tree | 9cfa50794201db3238e13b763b6931edd512d705 | |
parent | bf5813ba9cefacad3e8535478747f61c45ed41c2 (diff) | |
download | vt100-rust-4e4f47cb9a66eab13a40b2f7bf2477695c0ff003.tar.gz vt100-rust-4e4f47cb9a66eab13a40b2f7bf2477695c0ff003.zip |
wide continuation cells should not have attributes
it confuses things like cell insertion
-rw-r--r-- | src/screen.rs | 2 | ||||
-rw-r--r-- | tests/data/fixtures/ich_dch_ech.in | 1 | ||||
-rw-r--r-- | tests/data/fixtures/ich_dch_ech/15.json | 18 | ||||
-rw-r--r-- | tests/data/fixtures/ich_dch_ech/15.typescript | 1 |
4 files changed, 21 insertions, 1 deletions
diff --git a/src/screen.rs b/src/screen.rs index 177a28e..2dba4b5 100644 --- a/src/screen.rs +++ b/src/screen.rs @@ -939,7 +939,7 @@ impl Screen { } } let next_cell = self.current_cell_mut(); - next_cell.clear(attrs); + next_cell.clear(crate::attrs::Attrs::default()); next_cell.set_wide_continuation(true); self.grid_mut().col_inc(1); } diff --git a/tests/data/fixtures/ich_dch_ech.in b/tests/data/fixtures/ich_dch_ech.in index ee7ec70..b152d5b 100644 --- a/tests/data/fixtures/ich_dch_ech.in +++ b/tests/data/fixtures/ich_dch_ech.in @@ -12,3 +12,4 @@ obar \x1b[1;80H \x1b[X \x1bc\x1b[1;78Hネab \x1b[H\x1b[@ +\x1bc\x1b[1mデ\x08\x1b[@ diff --git a/tests/data/fixtures/ich_dch_ech/15.json b/tests/data/fixtures/ich_dch_ech/15.json new file mode 100644 index 0000000..ec03132 --- /dev/null +++ b/tests/data/fixtures/ich_dch_ech/15.json @@ -0,0 +1,18 @@ +{ + "contents": "デ", + "cells": { + "0,0": { + "contents": "デ", + "is_wide": true, + "bold": true + }, + "0,1": { + "contents": "", + "is_wide_continuation": true + } + }, + "cursor_position": [ + 0, + 1 + ] +}
\ No newline at end of file diff --git a/tests/data/fixtures/ich_dch_ech/15.typescript b/tests/data/fixtures/ich_dch_ech/15.typescript new file mode 100644 index 0000000..8c83609 --- /dev/null +++ b/tests/data/fixtures/ich_dch_ech/15.typescript @@ -0,0 +1 @@ +c[1mデ[@
\ No newline at end of file |