Function cosmic::iced_widget::opaque
source · pub fn opaque<'a, Message, Theme, Renderer>(
content: impl Into<Element<'a, Message, Theme, Renderer>>,
) -> Element<'a, Message, Theme, Renderer>where
Message: 'a,
Theme: 'a,
Renderer: Renderer + 'a,
Expand description
Wraps the given widget and captures any mouse button presses inside the bounds of the widget—effectively making it opaque.
This helper is meant to be used to mark elements in a Stack
to avoid mouse
events from passing through layers.