diff --git a/src/main.rs b/src/main.rs index 59b4151..62f5087 100644 --- a/src/main.rs +++ b/src/main.rs @@ -170,11 +170,18 @@ impl State { fn subscription(&self) -> Subscription { event::listen().map(Message::Event) } + fn title(&self) -> String { + match self.image.as_ref() { + Some(image) => format!("imagey {}x{}", image.width(), image.height()), + None => format!("imagey"), + } + } } fn main() -> Result<(), iced::Error> { iced::application(State::new, State::update, State::view) .subscription(State::subscription) + .title(State::title) .theme(Theme::custom( "custom", theme::Palette {