pub struct ToolbarItem<Msg = Callback> { /* private fields */ }Expand description
One item of the bar: a built-in editing action, or the application’s own.
Implementations§
Source§impl<Msg> ToolbarItem<Msg>
impl<Msg> ToolbarItem<Msg>
Sourcepub fn action(action: EditAction) -> Self
pub fn action(action: EditAction) -> Self
A built-in item, with its own words.
Sourcepub fn select_all() -> Self
pub fn select_all() -> Self
Select all.
Sourcepub fn custom(label: impl Into<String>, message: Msg) -> Self
pub fn custom(label: impl Into<String>, message: Msg) -> Self
An item of the application’s own: message is what pressing it sends, like any
button. The bar closes when it is pressed.
Sourcepub fn edit_action(&self) -> Option<EditAction>
pub fn edit_action(&self) -> Option<EditAction>
The built-in action this item performs, or None for an application’s own item.
Trait Implementations§
Auto Trait Implementations§
impl<Msg> Freeze for ToolbarItem<Msg>where
ItemKind<Msg>: Freeze,
impl<Msg> RefUnwindSafe for ToolbarItem<Msg>where
ItemKind<Msg>: RefUnwindSafe,
impl<Msg> Send for ToolbarItem<Msg>where
ItemKind<Msg>: Send,
impl<Msg> Sync for ToolbarItem<Msg>where
ItemKind<Msg>: Sync,
impl<Msg> Unpin for ToolbarItem<Msg>where
ItemKind<Msg>: Unpin,
impl<Msg> UnsafeUnpin for ToolbarItem<Msg>where
ItemKind<Msg>: UnsafeUnpin,
impl<Msg> UnwindSafe for ToolbarItem<Msg>where
ItemKind<Msg>: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more