1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
use crate::Component;
use std::fmt;
use termcolor::ColorChoice;
#[derive(Component)]
#[component(core)]
pub struct Terminal {}
impl Terminal {
pub fn new(color_choice: ColorChoice) -> Terminal {
super::init(color_choice);
if color_choice != ColorChoice::Never {
color_backtrace::install();
}
Self {}
}
}
impl fmt::Debug for Terminal {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(f, "TerminalComponent {{ stdout, stderr }}")
}
}