hecto/src/highlighting.rs
2021-03-15 14:53:08 -04:00

19 lines
347 B
Rust

use termion::color;
#[derive(PartialEq)]
pub enum Type {
None,
Number,
Match,
}
impl Type {
pub fn to_color(&self) -> impl color::Color {
match self {
Type::Number => color::Rgb(220, 163, 163),
Type::Match => color::Rgb(38, 139, 210),
_ => color::Rgb(255, 255, 255),
}
}
}