#[non_exhaustive]pub struct SelectStyle {Show 13 fields
pub variant: Option<FieldVariant>,
pub height: Option<Pixels>,
pub padding_x: Option<Pixels>,
pub padding_y: Option<Pixels>,
pub trigger_text_size: Option<Pixels>,
pub row_height: Option<Pixels>,
pub row_padding_x: Option<Pixels>,
pub row_padding_y: Option<Pixels>,
pub row_text_size: Option<Pixels>,
pub panel_padding: Option<Pixels>,
pub radius: Option<Pixels>,
pub row_hover_bg: Option<ComponentColor>,
pub is_bare: Option<bool>,
}Expand description
Select trigger and detached option-panel presentation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.variant: Option<FieldVariant>Field variant.
height: Option<Pixels>Trigger height.
padding_x: Option<Pixels>Horizontal padding on the trigger.
padding_y: Option<Pixels>Vertical padding on the trigger, in place of v3’s py-2.
The trigger is min-h based, so a single-line value keeps the
resolved height (36px of line-height: 20px plus 8px each side)
while a value that wraps to two lines grows the trigger the way
upstream’s py-2 does. Unset leaves the trigger unpadded, which is
the pre-0.10.0 geometry.
trigger_text_size: Option<Pixels>Text size in the trigger.
row_height: Option<Pixels>Option row height.
row_padding_x: Option<Pixels>Horizontal padding on an option row.
row_padding_y: Option<Pixels>Vertical padding on an option row.
row_text_size: Option<Pixels>Text size in an option row.
panel_padding: Option<Pixels>Padding inside the option panel.
radius: Option<Pixels>Corner radius.
row_hover_bg: Option<ComponentColor>Background of a hovered option row.
is_bare: Option<bool>Whether the trigger drops its own field chrome.
Implementations§
Source§impl SelectStyle
impl SelectStyle
Sourcepub fn variant(self, value: impl Into<FieldVariant>) -> Self
pub fn variant(self, value: impl Into<FieldVariant>) -> Self
Field variant.
Sourcepub fn padding_y(self, value: impl Into<Pixels>) -> Self
pub fn padding_y(self, value: impl Into<Pixels>) -> Self
Vertical padding on the trigger, in place of v3’s py-2.
The trigger is min-h based, so a single-line value keeps the
resolved height (36px of line-height: 20px plus 8px each side)
while a value that wraps to two lines grows the trigger the way
upstream’s py-2 does. Unset leaves the trigger unpadded, which is
the pre-0.10.0 geometry.
Sourcepub fn trigger_text_size(self, value: impl Into<Pixels>) -> Self
pub fn trigger_text_size(self, value: impl Into<Pixels>) -> Self
Text size in the trigger.
Sourcepub fn row_height(self, value: impl Into<Pixels>) -> Self
pub fn row_height(self, value: impl Into<Pixels>) -> Self
Option row height.
Sourcepub fn row_padding_x(self, value: impl Into<Pixels>) -> Self
pub fn row_padding_x(self, value: impl Into<Pixels>) -> Self
Horizontal padding on an option row.
Sourcepub fn row_padding_y(self, value: impl Into<Pixels>) -> Self
pub fn row_padding_y(self, value: impl Into<Pixels>) -> Self
Vertical padding on an option row.
Sourcepub fn row_text_size(self, value: impl Into<Pixels>) -> Self
pub fn row_text_size(self, value: impl Into<Pixels>) -> Self
Text size in an option row.
Sourcepub fn panel_padding(self, value: impl Into<Pixels>) -> Self
pub fn panel_padding(self, value: impl Into<Pixels>) -> Self
Padding inside the option panel.
Sourcepub fn row_hover_bg(self, value: impl Into<ComponentColor>) -> Self
pub fn row_hover_bg(self, value: impl Into<ComponentColor>) -> Self
Background of a hovered option row.
Trait Implementations§
Source§impl Clone for SelectStyle
impl Clone for SelectStyle
Source§impl ComponentStyle for SelectStyle
impl ComponentStyle for SelectStyle
Source§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 UnsafeUnpin 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
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<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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> ⓘ
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> ⓘ
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().