pub struct StackChildPosition {
pub left: Option<f64>,
pub right: Option<f64>,
pub top: Option<f64>,
pub bottom: Option<f64>,
pub width: Option<f64>,
pub height: Option<f64>,
}Expand description
Stack child position
Stack children are positioned relative to the container edges.
Horizontal position is determined by (left, right, width). Maximal two of those values may be defined (one value need
to be None).
Vertical position is determined by (top, bottom, height). Maximal two of those values may be defined (one value
need to be None).
If width or height is unconstrained, they are positioned
according to the Stack::align property.
Fields§
§left: Option<f64>Disance from left edge.
right: Option<f64>Disance from right edge.
top: Option<f64>Disance from top edge.
bottom: Option<f64>Disance from bottom edge.
width: Option<f64>Widget width.
height: Option<f64>Widhet height.
Implementations§
Source§impl StackChildPosition
impl StackChildPosition
Sourcepub fn left(self, value: Option<f64>) -> Self
pub fn left(self, value: Option<f64>) -> Self
Builder-style method to set distance from left edge.
Sourcepub fn right(self, value: Option<f64>) -> Self
pub fn right(self, value: Option<f64>) -> Self
Builder-style method to set distance from right edge.
Sourcepub fn top(self, value: Option<f64>) -> Self
pub fn top(self, value: Option<f64>) -> Self
Builder-style method to set distance from top edge.
Trait Implementations§
Source§impl Clone for StackChildPosition
impl Clone for StackChildPosition
Source§fn clone(&self) -> StackChildPosition
fn clone(&self) -> StackChildPosition
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 Data for StackChildPosition
impl Data for StackChildPosition
Source§impl Debug for StackChildPosition
impl Debug for StackChildPosition
Source§impl Default for StackChildPosition
impl Default for StackChildPosition
Source§fn default() -> StackChildPosition
fn default() -> StackChildPosition
Returns the “default value” for a type. Read more
Source§impl<T> From<StackChildPosition> for StackChildParams<T>
impl<T> From<StackChildPosition> for StackChildParams<T>
Source§fn from(position: StackChildPosition) -> Self
fn from(position: StackChildPosition) -> Self
Converts to this type from the input type.
Source§impl Interpolate for StackChildPosition
impl Interpolate for StackChildPosition
fn interpolate(&self, other: &Self, fraction: f64) -> Self
Source§impl PartialEq for StackChildPosition
impl PartialEq for StackChildPosition
impl StructuralPartialEq for StackChildPosition
Auto Trait Implementations§
impl Freeze for StackChildPosition
impl RefUnwindSafe for StackChildPosition
impl Send for StackChildPosition
impl Sync for StackChildPosition
impl Unpin for StackChildPosition
impl UnwindSafe for StackChildPosition
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> 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, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
Source§fn round_into(self) -> U
fn round_into(self) -> U
Performs the conversion.