[][src]Trait uniui_gui::Widget

pub trait Widget: DataProcessor {
    fn to_native(
        &mut self,
        _widget_generator: &mut dyn WidgetGenerator
    ) -> Result<NativeWidget, ()>; fn draw(&mut self) { ... } }

Minimal UI element.

Widget represents minimal UI element. Most common widgets is Button and TextEdit.

Required methods

fn to_native(
    &mut self,
    _widget_generator: &mut dyn WidgetGenerator
) -> Result<NativeWidget, ()>

Generate native widget

Loading content...

Provided methods

fn draw(&mut self)

Allows drawing on top of generated NativeWidget

Loading content...

Implementors

Loading content...