Done updating rendering performance for now. Further changes would require more fundamental work, I'm still not really happy with it as is though. Will probably take a few hours to clean the code though.
This commit is contained in:
parent
005e2cb2be
commit
ef1a32ee92
4 changed files with 82 additions and 62 deletions
|
@ -61,13 +61,17 @@ impl<'a> TerminalTestContext<'a> {
|
|||
}
|
||||
|
||||
fn grid_as_str(connection: &TerminalConnection) -> String {
|
||||
let grid = connection.get_terminal().unwrap().grid();
|
||||
let lines = grid.display_iter().group_by(|i| i.point.line.0);
|
||||
lines
|
||||
.into_iter()
|
||||
.map(|(_, line)| line.map(|i| i.c).collect::<String>())
|
||||
.collect::<Vec<String>>()
|
||||
.join("\n")
|
||||
connection
|
||||
.get_terminal()
|
||||
.unwrap()
|
||||
.render_lock(None, |content| {
|
||||
let lines = content.display_iter.group_by(|i| i.point.line.0);
|
||||
lines
|
||||
.into_iter()
|
||||
.map(|(_, line)| line.map(|i| i.c).collect::<String>())
|
||||
.collect::<Vec<String>>()
|
||||
.join("\n")
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue