pub struct ScrollbarDrawInfo {Show 14 fields
pub bounds: LogicalRect,
pub orientation: ScrollbarOrientation,
pub track_bounds: LogicalRect,
pub track_color: ColorU,
pub thumb_bounds: LogicalRect,
pub thumb_color: ColorU,
pub thumb_border_radius: BorderRadius,
pub button_decrement_bounds: Option<LogicalRect>,
pub button_increment_bounds: Option<LogicalRect>,
pub button_color: ColorU,
pub opacity_key: Option<OpacityKey>,
pub hit_id: Option<ScrollbarHitId>,
pub clip_to_container_border: bool,
pub container_border_radius: BorderRadius,
}Expand description
Complete drawing information for a scrollbar with all visual components.
This contains the resolved geometry and colors for all scrollbar parts:
- Track: The background area where the thumb slides
- Thumb: The draggable indicator showing current scroll position
- Buttons: Optional up/down or left/right arrow buttons
- Corner: The area where horizontal and vertical scrollbars meet
Fields§
§bounds: LogicalRectOverall bounds of the entire scrollbar (including track and buttons)
orientation: ScrollbarOrientationScrollbar orientation (horizontal or vertical)
track_bounds: LogicalRectBounds of the track area
track_color: ColorUColor of the track background
thumb_bounds: LogicalRectBounds of the thumb
thumb_color: ColorUColor of the thumb
thumb_border_radius: BorderRadiusBorder radius for rounded thumb corners
Optional decrement button bounds (up/left arrow)
Optional increment button bounds (down/right arrow)
Color for buttons
opacity_key: Option<OpacityKey>Optional opacity key for GPU-side fading animation.
hit_id: Option<ScrollbarHitId>Optional hit-test ID for WebRender hit-testing.
clip_to_container_border: boolWhether to clip scrollbar to container’s border-radius
container_border_radius: BorderRadiusContainer’s border-radius (for clipping)
Trait Implementations§
Source§impl Clone for ScrollbarDrawInfo
impl Clone for ScrollbarDrawInfo
Source§fn clone(&self) -> ScrollbarDrawInfo
fn clone(&self) -> ScrollbarDrawInfo
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 moreAuto Trait Implementations§
impl Freeze for ScrollbarDrawInfo
impl RefUnwindSafe for ScrollbarDrawInfo
impl Send for ScrollbarDrawInfo
impl Sync for ScrollbarDrawInfo
impl Unpin for ScrollbarDrawInfo
impl UnwindSafe for ScrollbarDrawInfo
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<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