pub struct ScrollSource {
pub scroll_bar: bool,
pub drag: DragScroll,
pub mouse_wheel: bool,
}Available on crate feature
egui only.Expand description
What is the source of scrolling for a ScrollArea.
Fields§
§scroll_bar: boolScroll the area by dragging a scroll bar.
By default the scroll bars remain visible to show current position.
To hide them use ScrollArea::scroll_bar_visibility().
drag: DragScrollScroll the area by dragging the contents.
Defaults to DragScroll::OnTouch: only active when a touch screen is
detected. Set to DragScroll::Always to force it on, or
DragScroll::Never to disable.
mouse_wheel: boolScroll the area by scrolling (or shift scrolling) the mouse wheel with
the mouse cursor over the ScrollArea.
Implementations§
Source§impl ScrollSource
impl ScrollSource
pub const NONE: ScrollSource
pub const ALL: ScrollSource
pub const SCROLL_BAR: ScrollSource
pub const DRAG: ScrollSource
pub const MOUSE_WHEEL: ScrollSource
Trait Implementations§
Source§impl Add for ScrollSource
impl Add for ScrollSource
Source§type Output = ScrollSource
type Output = ScrollSource
The resulting type after applying the
+ operator.Source§fn add(self, rhs: ScrollSource) -> <ScrollSource as Add>::Output
fn add(self, rhs: ScrollSource) -> <ScrollSource as Add>::Output
Performs the
+ operation. Read moreSource§impl AddAssign for ScrollSource
impl AddAssign for ScrollSource
Source§fn add_assign(&mut self, rhs: ScrollSource)
fn add_assign(&mut self, rhs: ScrollSource)
Performs the
+= operation. Read moreSource§impl BitOr for ScrollSource
impl BitOr for ScrollSource
Source§type Output = ScrollSource
type Output = ScrollSource
The resulting type after applying the
| operator.Source§fn bitor(self, rhs: ScrollSource) -> <ScrollSource as BitOr>::Output
fn bitor(self, rhs: ScrollSource) -> <ScrollSource as BitOr>::Output
Performs the
| operation. Read moreSource§impl BitOrAssign for ScrollSource
impl BitOrAssign for ScrollSource
Source§fn bitor_assign(&mut self, rhs: ScrollSource)
fn bitor_assign(&mut self, rhs: ScrollSource)
Performs the
|= operation. Read moreSource§impl Clone for ScrollSource
impl Clone for ScrollSource
Source§fn clone(&self) -> ScrollSource
fn clone(&self) -> ScrollSource
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 moreimpl Copy for ScrollSource
Source§impl Debug for ScrollSource
impl Debug for ScrollSource
Source§impl Default for ScrollSource
impl Default for ScrollSource
Source§fn default() -> ScrollSource
fn default() -> ScrollSource
scroll_bar and mouse_wheel enabled; drag set to DragScroll::OnTouch.
impl Eq for ScrollSource
Source§impl PartialEq for ScrollSource
impl PartialEq for ScrollSource
impl StructuralPartialEq for ScrollSource
Auto Trait Implementations§
impl Forget for ScrollSource
impl Freeze for ScrollSource
impl Move for ScrollSource
impl RefUnwindSafe for ScrollSource
impl Send for ScrollSource
impl Sync for ScrollSource
impl Unpin for ScrollSource
impl UnsafeUnpin for ScrollSource
impl UnwindSafe for ScrollSource
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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§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> 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