New pallete

This commit is contained in:
Jiří Maxmilián Stříbrný 2026-04-02 13:33:44 +02:00
parent 83b396ae3e
commit 524e6365ca
3 changed files with 15 additions and 76 deletions

View file

@ -5,10 +5,10 @@ use crate::widgets::power_management::PowerManagementWidget;
use crate::widgets::powerbutton::ShutdownWidget;
use crate::widgets::spacer::Spacer;
use iced::Color;
use iced::Element;
use iced::Subscription;
use iced::Task;
use iced::{Color, Theme};
use iced::{Element, color};
pub struct App {
widgets: Vec<Box<dyn PanelWidget>>,
@ -68,7 +68,16 @@ impl App {
}
pub fn theme(&self, _id: iced::window::Id) -> iced::Theme {
iced::Theme::GruvboxDark
let palette = iced::theme::Palette {
background: color!(0x282828), // dark BG_0
text: color!(0xfbf1c7), // dark FG0_29
primary: color!(0x8A493B), // dark BLUE_4
success: color!(0x98971a), // dark GREEN_2
warning: color!(0xd79921), // dark YELLOW_3
danger: color!(0xcc241d), // dark RED_1
};
Theme::custom("Better gruvbox", palette)
}
pub fn subscription(&self) -> iced::Subscription<Message> {