[][src]Trait egui::app::App

pub trait App {
    fn ui(&mut self, ui: &mut Ui, backend: &mut dyn Backend);

    fn on_exit(&mut self, _storage: &mut dyn Storage) { ... }
}

Implement this trait to write apps that can be compiled both natively using the egui_glium crate, and deployed as a web site using the egui_web crate.

Required methods

fn ui(&mut self, ui: &mut Ui, backend: &mut dyn Backend)

Called each time the UI needs repainting, which may be many times per second.

Loading content...

Provided methods

fn on_exit(&mut self, _storage: &mut dyn Storage)

Called once on shutdown. Allows you to save state.

Loading content...

Implementors

impl App for DemoApp[src]

Loading content...