Skip to content

Commit

Permalink
Add general.default_icon option to specify fallback icon
Browse files Browse the repository at this point in the history
  • Loading branch information
bbrks committed Jun 1, 2020
1 parent 2ea42df commit 877d315
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,10 @@ fn get_class(conn: &xcb::Connection, id: u32, options: &Options) -> Result<Strin
format!("{}", icon)
}
}
None => format!("{}", class_display_name),
None => match options.general.get("default_icon") {
Some(default_icon) => format!("{} {}", default_icon, class_display_name),
None => format!("{}", class_display_name),
},
}
});

Expand Down

0 comments on commit 877d315

Please sign in to comment.