pub struct TabOverview<Msg: Clone> { /* private fields */ }Implementations§
Source§impl<Msg: Clone + 'static> TabOverview<Msg>
impl<Msg: Clone + 'static> TabOverview<Msg>
pub fn new(tabs: impl IntoIterator<Item = TabItem>) -> Self
pub fn selected(self, idx: usize) -> Self
pub fn on_select(self, f: impl Fn(usize) -> Msg + 'static) -> Self
pub fn on_close(self, f: impl Fn(usize) -> Msg + 'static) -> Self
Sourcepub fn reorderable(self, reorderable: bool) -> Self
pub fn reorderable(self, reorderable: bool) -> Self
Whether the cards can be dragged into another order, as TabStrip::reorderable. Default: false.
Sourcepub fn motion(self, motion: &TabMotion) -> Self
pub fn motion(self, motion: &TabMotion) -> Self
The state a drag goes through; the strip’s may be handed here too.
pub fn title(self, title: impl Into<String>) -> Self
Sourcepub fn back(self, msg: Msg) -> Self
pub fn back(self, msg: Msg) -> Self
The message of the back button at the header’s left; without it there is none.
Sourcepub fn action(self, button: impl Into<Element<Msg>>) -> Self
pub fn action(self, button: impl Into<Element<Msg>>) -> Self
A button at the header’s right, such as a new tab button.
pub fn colors(self, colors: TabStripColors) -> Self
Trait Implementations§
Source§impl<Msg: Clone + 'static> From<TabOverview<Msg>> for Element<Msg>
impl<Msg: Clone + 'static> From<TabOverview<Msg>> for Element<Msg>
Source§fn from(overview: TabOverview<Msg>) -> Self
fn from(overview: TabOverview<Msg>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<Msg> Freeze for TabOverview<Msg>where
Msg: Freeze,
impl<Msg> !RefUnwindSafe for TabOverview<Msg>
impl<Msg> !Send for TabOverview<Msg>
impl<Msg> !Sync for TabOverview<Msg>
impl<Msg> Unpin for TabOverview<Msg>where
Msg: Unpin,
impl<Msg> !UnwindSafe for TabOverview<Msg>
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more