pub struct ScrollViewState { /* private fields */ }
Implementations§
Source§impl ScrollViewState
impl ScrollViewState
Sourcepub fn with_offset(offset: Position) -> Self
pub fn with_offset(offset: Position) -> Self
Create a new scroll view state with the given offset
Sourcepub fn set_offset(&mut self, offset: Position)
pub fn set_offset(&mut self, offset: Position)
Set the offset of the scroll view state
Sourcepub fn scroll_down(&mut self)
pub fn scroll_down(&mut self)
Move the scroll view state down by one row
Sourcepub fn scroll_page_down(&mut self)
pub fn scroll_page_down(&mut self)
Move the scroll view state down by one page
Sourcepub fn scroll_page_up(&mut self)
pub fn scroll_page_up(&mut self)
Move the scroll view state up by one page
Sourcepub fn scroll_left(&mut self)
pub fn scroll_left(&mut self)
Move the scroll view state left by one column
Sourcepub fn scroll_right(&mut self)
pub fn scroll_right(&mut self)
Move the scroll view state right by one column
Sourcepub fn scroll_to_top(&mut self)
pub fn scroll_to_top(&mut self)
Move the scroll view state to the top of the buffer
Sourcepub fn scroll_to_bottom(&mut self)
pub fn scroll_to_bottom(&mut self)
Move the scroll view state to the bottom of the buffer
Trait Implementations§
Source§impl Clone for ScrollViewState
impl Clone for ScrollViewState
Source§fn clone(&self) -> ScrollViewState
fn clone(&self) -> ScrollViewState
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 Debug for ScrollViewState
impl Debug for ScrollViewState
Source§impl Default for ScrollViewState
impl Default for ScrollViewState
Source§fn default() -> ScrollViewState
fn default() -> ScrollViewState
Returns the “default value” for a type. Read more
Source§impl Hash for ScrollViewState
impl Hash for ScrollViewState
Source§impl PartialEq for ScrollViewState
impl PartialEq for ScrollViewState
impl Copy for ScrollViewState
impl Eq for ScrollViewState
impl StructuralPartialEq for ScrollViewState
Auto Trait Implementations§
impl Freeze for ScrollViewState
impl RefUnwindSafe for ScrollViewState
impl Send for ScrollViewState
impl Sync for ScrollViewState
impl Unpin for ScrollViewState
impl UnwindSafe for ScrollViewState
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.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