pub enum TabAlignment {
Start,
StartOffset,
Fill,
Center,
}Expand description
Defines how tabs are aligned horizontally in a TabBar.
See also:
TabBar, which displays a row of tabs.TabBarView, which displays a widget for the currently selected tab.TabBar::tab_alignment, which defines the horizontal alignment of the tabs within theTabBar.
Variants§
Start
If TabBar::is_scrollable is true, tabs are aligned to the
start of the TabBar. Otherwise throws an exception.
It is not recommended to set TabAlignment::Start when
ThemeData::use_material3 is false.
StartOffset
If TabBar::is_scrollable is true, tabs are aligned to the
start of the TabBar with an offset of 52.0 pixels.
Otherwise throws an exception.
It is not recommended to set TabAlignment::StartOffset when
ThemeData::use_material3 is false.
Fill
If TabBar::is_scrollable is false, tabs are stretched to fill the
TabBar. Otherwise throws an exception.
Center
Tabs are aligned to the center of the TabBar.
Trait Implementations§
Source§impl Clone for TabAlignment
impl Clone for TabAlignment
impl Copy for TabAlignment
Source§impl Debug for TabAlignment
impl Debug for TabAlignment
impl Eq for TabAlignment
Source§impl Hash for TabAlignment
impl Hash for TabAlignment
Source§impl PartialEq for TabAlignment
impl PartialEq for TabAlignment
impl StructuralPartialEq for TabAlignment
Auto Trait Implementations§
impl Forget for TabAlignment
impl Freeze for TabAlignment
impl Move for TabAlignment
impl RefUnwindSafe for TabAlignment
impl Send for TabAlignment
impl Sync for TabAlignment
impl Unpin for TabAlignment
impl UnsafeUnpin for TabAlignment
impl UnwindSafe for TabAlignment
Blanket Implementations§
Source§impl<T> AnyEq for T
impl<T> AnyEq for T
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.