pub struct WidthCalculatedRect {
pub preferred_width: WhConstraint,
pub margin_right: Option<CssPropertyValue<LayoutMarginRight>>,
pub margin_left: Option<CssPropertyValue<LayoutMarginLeft>>,
pub padding_right: Option<CssPropertyValue<LayoutPaddingRight>>,
pub padding_left: Option<CssPropertyValue<LayoutPaddingLeft>>,
pub border_right: Option<CssPropertyValue<LayoutBorderRightWidth>>,
pub border_left: Option<CssPropertyValue<LayoutBorderLeftWidth>>,
pub box_sizing: LayoutBoxSizing,
pub left: Option<CssPropertyValue<LayoutLeft>>,
pub right: Option<CssPropertyValue<LayoutRight>>,
pub flex_grow_px: f32,
pub min_inner_size_px: f32,
}Fields§
§preferred_width: WhConstraint§margin_right: Option<CssPropertyValue<LayoutMarginRight>>§margin_left: Option<CssPropertyValue<LayoutMarginLeft>>§padding_right: Option<CssPropertyValue<LayoutPaddingRight>>§padding_left: Option<CssPropertyValue<LayoutPaddingLeft>>§border_right: Option<CssPropertyValue<LayoutBorderRightWidth>>§border_left: Option<CssPropertyValue<LayoutBorderLeftWidth>>§box_sizing: LayoutBoxSizing§left: Option<CssPropertyValue<LayoutLeft>>§right: Option<CssPropertyValue<LayoutRight>>§flex_grow_px: f32§min_inner_size_px: f32Implementations§
Source§impl WidthCalculatedRect
impl WidthCalculatedRect
pub fn overflow_width(&self) -> f32
pub fn get_border_left(&self, percent_resolve: f32) -> f32
pub fn get_border_right(&self, percent_resolve: f32) -> f32
pub fn get_raw_padding_left(&self, percent_resolve: f32) -> f32
pub fn get_raw_padding_right(&self, percent_resolve: f32) -> f32
pub fn get_padding_left(&self, percent_resolve: f32) -> f32
pub fn get_padding_right(&self, percent_resolve: f32) -> f32
pub fn get_margin_left(&self, percent_resolve: f32) -> f32
pub fn get_margin_right(&self, percent_resolve: f32) -> f32
Sourcepub fn get_flex_basis_horizontal(&self, parent_width: f32) -> f32
pub fn get_flex_basis_horizontal(&self, parent_width: f32) -> f32
Get the flex basis in the horizontal direction - vertical axis has to be calculated differently
pub fn get_horizontal_border(&self, parent_width: f32) -> f32
Sourcepub fn get_horizontal_padding(&self, parent_width: f32) -> f32
pub fn get_horizontal_padding(&self, parent_width: f32) -> f32
Get the sum of the horizontal padding amount (padding.left + padding.right)
Sourcepub fn get_horizontal_margin(&self, parent_width: f32) -> f32
pub fn get_horizontal_margin(&self, parent_width: f32) -> f32
Get the sum of the horizontal padding amount (margin.left + margin.right)
pub fn solved_result(&self) -> WidthSolvedResult
Trait Implementations§
Source§impl Clone for WidthCalculatedRect
impl Clone for WidthCalculatedRect
Source§fn clone(&self) -> WidthCalculatedRect
fn clone(&self) -> WidthCalculatedRect
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 WidthCalculatedRect
impl Debug for WidthCalculatedRect
Source§impl Default for WidthCalculatedRect
impl Default for WidthCalculatedRect
Source§fn default() -> WidthCalculatedRect
fn default() -> WidthCalculatedRect
Returns the “default value” for a type. Read more
Source§impl PartialEq for WidthCalculatedRect
impl PartialEq for WidthCalculatedRect
impl Copy for WidthCalculatedRect
impl StructuralPartialEq for WidthCalculatedRect
Auto Trait Implementations§
impl Freeze for WidthCalculatedRect
impl RefUnwindSafe for WidthCalculatedRect
impl Send for WidthCalculatedRect
impl Sync for WidthCalculatedRect
impl Unpin for WidthCalculatedRect
impl UnwindSafe for WidthCalculatedRect
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