From 271b71958a6ec91794d2284e9fd4d4af552600a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vuka=C5=A1in=20Vojinovi=C4=87?= Date: Thu, 19 Sep 2024 12:32:13 +0200 Subject: [PATCH] fix(menu): use accent color for checkbox Uses the accent color for the checkmark, to match designs. --- src/widget/menu/menu_tree.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/widget/menu/menu_tree.rs b/src/widget/menu/menu_tree.rs index f1aab35..7068fd2 100644 --- a/src/widget/menu/menu_tree.rs +++ b/src/widget/menu/menu_tree.rs @@ -4,6 +4,7 @@ use std::borrow::Cow; use std::collections::HashMap; +use std::rc::Rc; use iced_widget::core::{renderer, Element}; @@ -257,10 +258,15 @@ where widget::icon::from_name("object-select-symbolic") .size(16) .icon() + .style(theme::Svg::Custom(Rc::new(|theme| { + crate::iced_style::svg::Appearance { + color: Some(theme.cosmic().accent_color().into()), + } + }))) .width(Length::Fixed(16.0)) .into() } else { - widget::Space::with_width(Length::Fixed(17.0)).into() + widget::Space::with_width(Length::Fixed(16.0)).into() }, widget::Space::with_width(Length::Fixed(8.0)).into(), widget::text(label)