pub struct SliverLogicalParentData {
pub layout_offset: Option<f64>,
}Expand description
Parent data structure used by parents of slivers that position their children using layout offsets.
This data structure is optimized for fast layout. It is best used by parents that expect to have many children whose relative positions don’t change even when the scroll offset does.
Fields§
§layout_offset: Option<f64>The position of the child relative to the zero scroll offset.
The number of pixels from the zero scroll offset of the parent sliver (the line at
which its SliverConstraints::scroll_offset is zero) to the side of the child closest
to that offset. It can be None when it cannot be determined. The value will be set
after layout.
In a typical list, this does not change as the parent is scrolled.
Implementations§
Source§impl SliverLogicalParentData
impl SliverLogicalParentData
Sourcepub const fn new() -> SliverLogicalParentData
pub const fn new() -> SliverLogicalParentData
Creates parent data with no layout offset.
Trait Implementations§
Source§impl Clone for SliverLogicalParentData
impl Clone for SliverLogicalParentData
impl Copy for SliverLogicalParentData
Source§impl Debug for SliverLogicalParentData
impl Debug for SliverLogicalParentData
Source§impl Default for SliverLogicalParentData
impl Default for SliverLogicalParentData
Source§impl Display for SliverLogicalParentData
impl Display for SliverLogicalParentData
Auto Trait Implementations§
impl Freeze for SliverLogicalParentData
impl RefUnwindSafe for SliverLogicalParentData
impl Send for SliverLogicalParentData
impl Sync for SliverLogicalParentData
impl Unpin for SliverLogicalParentData
impl UnsafeUnpin for SliverLogicalParentData
impl UnwindSafe for SliverLogicalParentData
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