[−][src]Trait iced_native::overlay::menu::Renderer
The renderer of a Menu.
Your renderer will need to implement this trait before being
able to use a Menu in your user interface.
Associated Types
Loading content...Required methods
fn decorate(
&mut self,
bounds: Rectangle,
cursor_position: Point,
style: &Self::Style,
primitive: Self::Output
) -> Self::Output
&mut self,
bounds: Rectangle,
cursor_position: Point,
style: &Self::Style,
primitive: Self::Output
) -> Self::Output
Decorates a the list of options of a Menu.
This method can be used to draw a background for the Menu.
fn draw<T: ToString>(
&mut self,
bounds: Rectangle,
cursor_position: Point,
options: &[T],
hovered_option: Option<usize>,
padding: u16,
text_size: u16,
font: Self::Font,
style: &Self::Style
) -> Self::Output
&mut self,
bounds: Rectangle,
cursor_position: Point,
options: &[T],
hovered_option: Option<usize>,
padding: u16,
text_size: u16,
font: Self::Font,
style: &Self::Style
) -> Self::Output
Draws the list of options of a Menu.