forked from mars/tml
37 lines
960 B
Rust
37 lines
960 B
Rust
use ansi_term::Style;
|
|
|
|
#[derive(Clone, Debug)]
|
|
pub struct Stylesheet {
|
|
pub header_style_float: Style,
|
|
pub header_style_floor: Style,
|
|
pub header_prefix: String,
|
|
pub p: Style,
|
|
pub underline: Style,
|
|
pub bold: Style,
|
|
pub italic: Style,
|
|
pub strikethrough: Style,
|
|
pub bullet: Style,
|
|
pub ul_prefix: String,
|
|
pub list_indent: usize,
|
|
}
|
|
|
|
impl Default for Stylesheet {
|
|
fn default() -> Self {
|
|
use ansi_term::Color::*;
|
|
|
|
Self {
|
|
header_style_float: Blue.bold(),
|
|
header_style_floor: Blue.bold().underline(),
|
|
header_prefix: "#".to_string(),
|
|
p: Style::new(),
|
|
underline: Style::new().underline(),
|
|
bold: Style::new().bold(),
|
|
italic: Style::new().italic(),
|
|
strikethrough: Style::new().strikethrough(),
|
|
bullet: Black.into(),
|
|
ul_prefix: "*".to_string(),
|
|
list_indent: 4,
|
|
}
|
|
}
|
|
}
|