pub trait ParamWidget {
    // Required method
    fn add_widget<P: Param>(
        &self,
        ui: &mut Ui,
        param: &P,
        setter: &ParamSetter<'_>
    );

    // Provided method
    unsafe fn add_widget_raw(
        &self,
        ui: &mut Ui,
        param: &ParamPtr,
        setter: &ParamSetter<'_>
    ) { ... }
}
Expand description

A widget that can be used to create a generic UI with. This is used in conjuction with empty structs to emulate existential types.

Required Methods§

source

fn add_widget<P: Param>(&self, ui: &mut Ui, param: &P, setter: &ParamSetter<'_>)

Provided Methods§

source

unsafe fn add_widget_raw( &self, ui: &mut Ui, param: &ParamPtr, setter: &ParamSetter<'_> )

The same as add_widget(), but for a ParamPtr.

Safety

Undefined behavior of the ParamPtr does not point to a valid parameter.

Implementors§