pub struct SelectStyle {
pub focused_border: Color,
pub unfocused_border: Color,
pub disabled_border: Color,
pub text_fg: Color,
pub placeholder_fg: Color,
pub dropdown_indicator: &'static str,
pub highlight_style: Style,
pub option_style: Style,
pub selected_indicator: &'static str,
pub unselected_indicator: &'static str,
pub dropdown_border: Color,
pub max_visible_options: u16,
}Expand description
Style configuration for select component.
Fields§
§focused_border: ColorBorder color when focused.
unfocused_border: ColorBorder color when unfocused.
disabled_border: ColorBorder color when disabled.
text_fg: ColorText color for selected value.
placeholder_fg: ColorPlaceholder text color.
dropdown_indicator: &'static strDropdown indicator (e.g., “▼”).
highlight_style: StyleHighlighted option style in dropdown.
option_style: StyleNormal option style in dropdown.
selected_indicator: &'static strSelected option indicator.
unselected_indicator: &'static strUnselected option indicator (padding).
dropdown_border: ColorDropdown border color.
max_visible_options: u16Max visible options in dropdown.
Implementations§
Source§impl SelectStyle
impl SelectStyle
Sourcepub fn max_options(self, max: u16) -> Self
pub fn max_options(self, max: u16) -> Self
Set max visible options in dropdown.
Sourcepub fn focused_border(self, color: Color) -> Self
pub fn focused_border(self, color: Color) -> Self
Set the focused border color.
Sourcepub fn unfocused_border(self, color: Color) -> Self
pub fn unfocused_border(self, color: Color) -> Self
Set the unfocused border color.
Trait Implementations§
Source§impl Clone for SelectStyle
impl Clone for SelectStyle
Source§fn clone(&self) -> SelectStyle
fn clone(&self) -> SelectStyle
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SelectStyle
impl Debug for SelectStyle
Auto Trait Implementations§
impl Freeze for SelectStyle
impl RefUnwindSafe for SelectStyle
impl Send for SelectStyle
impl Sync for SelectStyle
impl Unpin for SelectStyle
impl UnwindSafe for SelectStyle
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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