pub enum Size {
Inner,
Fill,
FillMinimum,
Percentage(Length),
Pixels(Length),
RootPercentage(Length),
InnerPercentage(Length),
DynamicCalculations(Box<Vec<DynamicCalculation>>),
}
Variants§
Inner
Fill
FillMinimum
Percentage(Length)
Pixels(Length)
RootPercentage(Length)
InnerPercentage(Length)
DynamicCalculations(Box<Vec<DynamicCalculation>>)
Implementations§
source§impl Size
impl Size
pub fn inner_sized(&self) -> bool
pub fn inner_percentage_sized(&self) -> bool
pub fn pretty(&self) -> String
pub fn eval( &self, parent_value: f32, available_parent_value: f32, parent_margin: f32, root_value: f32, phase: Phase ) -> Option<f32>
pub fn min_max( &self, value: f32, parent_value: f32, available_parent_value: f32, single_margin: f32, margin: f32, minimum: &Self, maximum: &Self, root_value: f32, phase: Phase ) -> f32
pub fn most_fitting_size<'a>( &self, size: &'a f32, available_size: &'a f32 ) -> &'a f32
Trait Implementations§
source§impl PartialEq for Size
impl PartialEq for Size
impl StructuralPartialEq for Size
Auto Trait Implementations§
impl Freeze for Size
impl RefUnwindSafe for Size
impl Send for Size
impl Sync for Size
impl Unpin for Size
impl UnwindSafe for Size
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> 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§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T, O> SuperFrom<T> for Owhere
O: From<T>,
impl<T, O> SuperFrom<T> for Owhere
O: From<T>,
§fn super_from(input: T) -> O
fn super_from(input: T) -> O
Convert from a type to another type.
§impl<T, O, M> SuperInto<O, M> for Twhere
O: SuperFrom<T, M>,
impl<T, O, M> SuperInto<O, M> for Twhere
O: SuperFrom<T, M>,
§fn super_into(self) -> O
fn super_into(self) -> O
Convert from a type to another type.