pub struct ScrollRegion {
pub id: usize,
pub x: f32,
pub y: f32,
pub width: f32,
pub height: f32,
pub content_width: f32,
pub content_height: f32,
pub max: Offset,
}Expand description
A scrollable box. id is its index in tree order, stable across rebuilds
as long as the tree’s shape is, which is what the shell keys offsets by.
Fields§
§id: usize§x: f32§y: f32§width: f32§height: f32§content_width: f32The size of the content inside, which may exceed the box on either axis.
content_height: f32§max: OffsetHow far the content can travel on each axis: content - visible (>= 0).
Implementations§
Trait Implementations§
Source§impl Clone for ScrollRegion
impl Clone for ScrollRegion
Source§fn clone(&self) -> ScrollRegion
fn clone(&self) -> ScrollRegion
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ScrollRegion
impl RefUnwindSafe for ScrollRegion
impl Send for ScrollRegion
impl Sync for ScrollRegion
impl Unpin for ScrollRegion
impl UnsafeUnpin for ScrollRegion
impl UnwindSafe for ScrollRegion
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