Struct zng_wgt_scroll::ScrollInfo
source · pub struct ScrollInfo(/* private fields */);
Expand description
Shared reference to the viewport bounds of a scroll.
Implementations§
source§impl ScrollInfo
impl ScrollInfo
sourcepub fn viewport_size(&self) -> PxSize
pub fn viewport_size(&self) -> PxSize
Gets the layout size of the viewport.
sourcepub fn viewport_transform(&self) -> PxTransform
pub fn viewport_transform(&self) -> PxTransform
Gets the render transform of the viewport.
sourcepub fn joiner_size(&self) -> PxSize
pub fn joiner_size(&self) -> PxSize
Gets the layout size of both scroll-bars.
Joiner here is the corner joiner visual, it is sized by the width of the vertical bar and height of the horizontal bar.
sourcepub fn content(&self) -> PxRect
pub fn content(&self) -> PxRect
Latest content offset and size.
This is the content bounds, scaled and in the viewport space.
sourcepub fn zoom_scale(&self) -> Factor
pub fn zoom_scale(&self) -> Factor
Latest zoom scale.
Trait Implementations§
source§impl Clone for ScrollInfo
impl Clone for ScrollInfo
source§fn clone(&self) -> ScrollInfo
fn clone(&self) -> ScrollInfo
Returns a copy 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 ScrollInfo
impl Debug for ScrollInfo
source§impl Default for ScrollInfo
impl Default for ScrollInfo
source§fn default() -> ScrollInfo
fn default() -> ScrollInfo
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ScrollInfo
impl !RefUnwindSafe for ScrollInfo
impl Send for ScrollInfo
impl Sync for ScrollInfo
impl Unpin for ScrollInfo
impl !UnwindSafe for ScrollInfo
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> FsChangeNote for T
impl<T> FsChangeNote for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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