iced-rs/iced

Less frameworky way to run the application

Open

#313 opened on Apr 22, 2020

View on GitHub
 (9 comments) (19 reactions) (0 assignees)Rust (30,491 stars) (1,572 forks)batch import
developer experiencefeaturehelp wantedshell

Description

Hello

First, I believe Iced is actually the first good-looking GUI API out there, so thanks!

Nevertheless, I have some small suggestion/feature request. There are two extremes how to run the application. One of them is the Application::run method that just takes care of everything and insists on managing the lifetime of the whole application, including setting up of a futures executor. On the other hand, there's the very low-level and manual way shown in https://github.com/hecrj/iced/blob/master/examples/integration/src/main.rs.

I'd like to have something in between. Something less verbose and more high level than the integration example, but something that's still flexible enough to let me setup (or reuse) eg. tokio threadpool the way I want, or to start the application, let it run until someone closes the window and then run some code afterwards. I'm not sure how exactly it looks inside, but for example hyper went from high-level „we manage everything“ serve method in previous versions to manual set up of server and converting it into a future one can spawn on the tokio executor.

I've tried scanning through the issues here and didn't find one similar, but maybe I'm not looking well enough.

Contributor guide