pub struct RootPadding { /* private fields */ }Expand description
Complete nonnegative owner-local RootPadding relationships.
Implementations§
Source§impl RootPadding
impl RootPadding
Sourcepub fn new(
left: RelativeSpacing,
right: RelativeSpacing,
bottom: RelativeSpacing,
top: RelativeSpacing,
) -> Result<Self>
pub fn new( left: RelativeSpacing, right: RelativeSpacing, bottom: RelativeSpacing, top: RelativeSpacing, ) -> Result<Self>
Construct all complete nonnegative local relationships.
Sourcepub fn get_left(&self) -> &RelativeSpacing
pub fn get_left(&self) -> &RelativeSpacing
Borrow the exact left relationship.
Sourcepub fn left(self, value: RelativeSpacing) -> Result<Self>
pub fn left(self, value: RelativeSpacing) -> Result<Self>
Replace only the exact left relationship.
Sourcepub fn get_right(&self) -> &RelativeSpacing
pub fn get_right(&self) -> &RelativeSpacing
Borrow the exact right relationship.
Sourcepub fn right(self, value: RelativeSpacing) -> Result<Self>
pub fn right(self, value: RelativeSpacing) -> Result<Self>
Replace only the exact right relationship.
Sourcepub fn get_bottom(&self) -> &RelativeSpacing
pub fn get_bottom(&self) -> &RelativeSpacing
Borrow the exact bottom relationship.
Sourcepub fn bottom(self, value: RelativeSpacing) -> Result<Self>
pub fn bottom(self, value: RelativeSpacing) -> Result<Self>
Replace only the exact bottom relationship.
Sourcepub fn get_top(&self) -> &RelativeSpacing
pub fn get_top(&self) -> &RelativeSpacing
Borrow the exact top relationship.
Sourcepub fn top(self, value: RelativeSpacing) -> Result<Self>
pub fn top(self, value: RelativeSpacing) -> Result<Self>
Replace only the exact top relationship.
Trait Implementations§
Source§impl Clone for RootPadding
impl Clone for RootPadding
Source§impl Debug for RootPadding
impl Debug for RootPadding
impl Eq for RootPadding
Source§impl PartialEq for RootPadding
impl PartialEq for RootPadding
impl StructuralPartialEq for RootPadding
Auto Trait Implementations§
impl Forget for RootPadding
impl Freeze for RootPadding
impl Move for RootPadding
impl RefUnwindSafe for RootPadding
impl Send for RootPadding
impl Sync for RootPadding
impl Unpin for RootPadding
impl UnsafeUnpin for RootPadding
impl UnwindSafe for RootPadding
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<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,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> Scalar for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.