-
public final class SeekerKt
-
-
Method Summary
Modifier and Type Method Description final static UnitSeeker(Modifier modifier, SeekerState state, Float value, Float thumbValue, ClosedFloatingPointRange<Float> range, @FloatRange(from = 0.0.toDouble(), to = 1.0.toDouble()) Float progressStartPosition, Float readAheadValue, Function1<Float, Unit> onValueChange, Function0<Unit> onValueChangeFinished, List<Segment> segments, Boolean enabled, SeekerColors colors, SeekerDimensions dimensions, MutableInteractionSource interactionSource)A seekbar/slider with support for read ahead indicator and segments. final static UnitSeekerPreview()-
-
Method Detail
-
Seeker
@Composable() final static Unit Seeker(Modifier modifier, SeekerState state, Float value, Float thumbValue, ClosedFloatingPointRange<Float> range, @FloatRange(from = 0.0.toDouble(), to = 1.0.toDouble()) Float progressStartPosition, Float readAheadValue, Function1<Float, Unit> onValueChange, Function0<Unit> onValueChangeFinished, List<Segment> segments, Boolean enabled, SeekerColors colors, SeekerDimensions dimensions, MutableInteractionSource interactionSource)
A seekbar/slider with support for read ahead indicator and segments. The segments can be separated with gaps in between or with their respective colors, or by both.
Read ahead indicator shows the amount of content which is ready to use.
- Parameters:
modifier- modifiers for the seeker layoutstate- state for Seekervalue- current value of the seeker.thumbValue- current value of the thumb.progressStartPosition- starting point of the indicator as a fraction of track width.readAheadValue- the read ahead value for seeker.onValueChange- lambda in which value should be updatedonValueChangeFinished- lambda to be invoked when value change has ended.segments- a list of Segment for seeker.enabled- whether or not component is enabled and can be interacted with or notcolors- SeekerColors that will be used to determine the color of the Slider parts in different state.dimensions- SeekerDimensions that will be used to determine the dimensions of different Seeker parts in different state.interactionSource- the MutableInteractionSource representing the stream of Interactions for this Seeker.
-
SeekerPreview
@Preview(showBackground = true)@Composable() final static Unit SeekerPreview()
-
-
-
-