diff --git a/src/state.rs b/src/state.rs index 67def41..d54939f 100644 --- a/src/state.rs +++ b/src/state.rs @@ -25,10 +25,8 @@ pub fn handle(term: &PseudoTerminal, area: Rect, buf: &mut Buffer) } if let Some(screen_cell) = screen.cell(row, col) { - if screen_cell.has_contents() { - let cell = buf.get_mut(buf_col, buf_row); - screen_cell.apply(cell); - } + let cell = buf.get_mut(buf_col, buf_row); + screen_cell.apply(cell); } } } diff --git a/src/vt100_imp.rs b/src/vt100_imp.rs index c63c3c2..a8aeb45 100644 --- a/src/vt100_imp.rs +++ b/src/vt100_imp.rs @@ -37,8 +37,11 @@ impl Cell for vt100::Cell { fn fill_buf_cell(screen_cell: &vt100::Cell, buf_cell: &mut ratatui::buffer::Cell) { let fg = screen_cell.fgcolor(); let bg = screen_cell.bgcolor(); - - buf_cell.set_symbol(&screen_cell.contents()); + if screen_cell.has_contents() { + buf_cell.set_symbol(&screen_cell.contents()); + } else { + buf_cell.set_symbol(" "); + } let fg: Color = fg.into(); let bg: Color = bg.into(); let mut style = Style::reset();