diff options
Diffstat (limited to 'src/config.rs')
| -rw-r--r-- | src/config.rs | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/config.rs b/src/config.rs index 66b8c8a..2af9af0 100644 --- a/src/config.rs +++ b/src/config.rs @@ -7,8 +7,8 @@ use std::fmt; use std::fs::read_to_string; use std::ops::Deref; -#[derive(Deserialize)] -#[serde(default)] +#[derive(Deserialize, Debug)] +#[serde(deny_unknown_fields, default)] pub struct Config { // colors pub background: Color, @@ -20,6 +20,8 @@ pub struct Config { pub tag_focused_bg: Color, pub tag_urgent_fg: Color, pub tag_urgent_bg: Color, + pub tag_inactive_fg: Color, + pub tag_inactive_bg: Color, // font and size pub font: Font, pub height: u32, @@ -29,6 +31,9 @@ pub struct Config { pub blocks_overlap: f64, // command pub command: Option<String>, + // misc + pub hide_inactive_tags: bool, + pub invert_touchpad_scrolling: bool, } impl Default for Config { @@ -44,6 +49,8 @@ impl Default for Config { tag_focused_bg: Color::from_rgba_hex(0x689d68ff), tag_urgent_fg: Color::from_rgba_hex(0x282828ff), tag_urgent_bg: Color::from_rgba_hex(0xcc241dff), + tag_inactive_fg: Color::from_rgba_hex(0xd79921ff), + tag_inactive_bg: Color::from_rgba_hex(0x282828ff), font: Font::new("monospace 10"), height: 24, separator_width: 2.0, @@ -51,6 +58,8 @@ impl Default for Config { blocks_r: 0.0, blocks_overlap: 0.0, command: None, + hide_inactive_tags: true, + invert_touchpad_scrolling: true, } } } @@ -79,6 +88,7 @@ impl Config { } } +#[derive(Debug)] pub struct Font(pub FontDescription); impl Font { |
