Skip to content

Commit

Permalink
fix: show icons even on empty [icon] section
Browse files Browse the repository at this point in the history
  • Loading branch information
l4l committed Dec 21, 2020
1 parent 182ee57 commit 74c3407
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/config/params.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,11 @@ impl<'a> From<&'a Config> for ListParams {
selected_font_color: select_conf!(noglob: config, list_items, selected_font_color)
.map(u32_to_solid_source)
.unwrap_or_else(|| SolidSource::from_unpremultiplied_argb(0xff, 0xa6, 0xe2, 0x2e)),
icon_size: select_conf!(noglob: config, icon, size).unwrap_or(0),
icon_size: config
.icon
.as_ref()
.map(|c| c.size.unwrap_or(DEFAULT_ICON_SIZE))
.unwrap_or(0),
fallback_icon: select_conf!(noglob: config, icon, fallback_icon_path)
.map(|path| Icon::load_icon(&path).expect("cannot load fallback icon")),
margin: select_conf!(noglob: config, list_items, margin).unwrap_or_else(|| Margin {
Expand Down

0 comments on commit 74c3407

Please sign in to comment.