pub enum FormLabel {
None,
Measure(u16),
Str(Cow<'static, str>),
Width(u16),
Size(u16, u16),
}Expand description
Label constraints.
Any given widths and heights will be reduced if there is not enough space.
Variants§
None
No label, just the widget.
Measure(u16)
Not a label, just a measure for column-width.
This will not create an output area but influences the label-width in the resulting layout.
unit: cols
Str(Cow<'static, str>)
Label by example. Line breaks in the text don’t work.
Will create a label area with the max width of all labels and a height of 1. The area will be top aligned with the widget.
Width(u16)
Label by width.
Will create a label area with the max width of all labels and a height of 1. The area will be top aligned with the widget.
unit: cols
Size(u16, u16)
Label by height+width.
Will create a label area with the max width of all labels and a height of rows. The area will be top aligned with the widget.
unit: cols,rows
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FormLabel
impl RefUnwindSafe for FormLabel
impl Send for FormLabel
impl Sync for FormLabel
impl Unpin for FormLabel
impl UnwindSafe for FormLabel
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> 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