diff options
author | Kyohei Uto <kyoheiu@outlook.com> | 2022-10-15 04:53:43 +0900 |
---|---|---|
committer | Kyohei Uto <kyoheiu@outlook.com> | 2022-10-15 04:53:43 +0900 |
commit | 06d260ab38530ed85ad410dec0fe0b39509349f2 (patch) | |
tree | 1259418b7944694de7580af854681809c848d812 /src/layout.rs | |
parent | eef48d48ca4538a30e93f1f159ddc7e6fea53d5f (diff) |
Add conversion from config color to crossterm color
Diffstat (limited to 'src/layout.rs')
-rw-r--r-- | src/layout.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/layout.rs b/src/layout.rs index f7234f9..4d4bee5 100644 --- a/src/layout.rs +++ b/src/layout.rs @@ -3,7 +3,6 @@ use super::errors::FxError; use super::functions::*; use super::state::{FileType, ItemInfo, BEGINNING_ROW}; use super::term::*; -use crossterm::style::Color; /// cf: https://docs.rs/image/latest/src/image/image.rs.html#84-112 pub const MAX_SIZE_TO_PREVIEW: u64 = 1_000_000_000; @@ -121,7 +120,7 @@ impl Layout { //Print preview (wrapping) for (i, line) in content.iter().enumerate() { move_to(self.preview_start_column, BEGINNING_ROW + i as u16); - set_foregroundcolor(Color::DarkGrey); + set_color(TermColor::ForeGround(Colorname::LightBlack)); print!("{}", line); reset_color(); if BEGINNING_ROW + i as u16 == self.terminal_row - 1 { |