Trait App

Source
pub trait App: Sized + 'static {
Show 13 methods // Required method fn render(&mut self, ctx: &Context, frame: &mut Frame); // Provided methods fn mobile_text_styles(&self) -> Option<BTreeMap<TextStyle, FontId>> { ... } fn default_text_styles(&self) -> Option<BTreeMap<TextStyle, FontId>> { ... } fn handle_event(&mut self, _ctx: &Context, _event: RuntimeEvent) { ... } fn handle_keyboard_events( &mut self, _key: Key, _pressed: bool, _modifiers: &Modifiers, _repeat: bool, ) { ... } fn device(&mut self) -> Option<&mut Device> { ... } fn init(&mut self, _runtime: &Runtime, _cc: &CreationContext<'_>) { ... } fn save(&mut self, _storage: &mut dyn Storage) { ... } fn on_exit(&mut self) { ... } fn auto_save_interval(&self) -> Duration { ... } fn clear_color(&self, _visuals: &Visuals) -> [f32; 4] { ... } fn persist_egui_memory(&self) -> bool { ... } fn raw_input_hook(&mut self, _ctx: &Context, _raw_input: &mut RawInput) { ... }
}

Required Methods§

Source

fn render(&mut self, ctx: &Context, frame: &mut Frame)

Provided Methods§

Source

fn mobile_text_styles(&self) -> Option<BTreeMap<TextStyle, FontId>>

Source

fn default_text_styles(&self) -> Option<BTreeMap<TextStyle, FontId>>

Source

fn handle_event(&mut self, _ctx: &Context, _event: RuntimeEvent)

Source

fn handle_keyboard_events( &mut self, _key: Key, _pressed: bool, _modifiers: &Modifiers, _repeat: bool, )

Source

fn device(&mut self) -> Option<&mut Device>

Source

fn init(&mut self, _runtime: &Runtime, _cc: &CreationContext<'_>)

Source

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

Source

fn on_exit(&mut self)

Source

fn auto_save_interval(&self) -> Duration

Time between automatic calls to Self::save

Source

fn clear_color(&self, _visuals: &Visuals) -> [f32; 4]

Source

fn persist_egui_memory(&self) -> bool

Source

fn raw_input_hook(&mut self, _ctx: &Context, _raw_input: &mut RawInput)

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§