agent_tui_domain/domain/core/
screen.rs1use super::CursorPosition;
4use super::style::CellStyle;
5
6pub trait ScreenGrid {
7 fn rows(&self) -> usize;
8 fn cols(&self) -> usize;
9 fn cell(&self, row: usize, col: usize) -> Option<(char, CellStyle)>;
10}
11
12#[derive(Debug, Clone, PartialEq, Eq)]
13pub struct ScreenCell {
14 pub ch: char,
15 pub style: CellStyle,
16}
17
18#[derive(Debug, Clone, PartialEq, Eq)]
19pub struct ScreenSnapshot {
20 pub cols: u16,
21 pub rows: u16,
22 pub cells: Vec<Vec<ScreenCell>>,
23 pub cursor: CursorPosition,
24}