Marker

interface Marker<T : Comparable<T>>(source)

Determines where marks are placed on a ValueSlider. These marks are used to indicate specific values or provide snapping behavior.

Functions

Link copied to clipboard
abstract fun marks(range: ClosedRange<T>, interpolator: Interpolator<T>): Sequence<Float>

A sequence of values that should be marked on a slider.

Link copied to clipboard
abstract fun nearest(range: ClosedRange<T>, interpolator: Interpolator<T>, progress: Float): Float?

Returns the closest marked value to progress based on the sequence that marks would return for the same range and interpolator.