Skip to main content

Module scroll

Module scroll 

Source
Expand description

§Scroll model

Repose separates visual scroll containers from scroll state.

This file implements inertial scroll states.

Velocities are expressed in px/sec and integrated with dt, so behavior is frame-rate independent.

Structs§

HorizontalScrollState
X-only state
ScrollState
Inertial scroll state (single axis Y).
ScrollStateXY
2D state

Functions§

HorizontalScrollArea
ScrollArea
Scroll container with inertia, like verticalScroll.
ScrollAreaXY
remember_horizontal_scroll_state
remember_scroll_state
Remembered ScrollState (requires unique key).
remember_scroll_state_xy