ProgressIndicator

fun ProgressIndicator(@FloatRange(from = 0.0, to = 1.0) progress: Float, modifier: Modifier = Modifier, shape: Shape = RectangleShape, backgroundColor: Color = Color.Unspecified, contentColor: Color = LocalContentColor.current, content: @Composable ProgressIndicatorScope.() -> Unit)

A foundational component used to build progress indicators.

For interactive preview & code examples, visit Progress Indicator Documentation.

Basic Example

ProgressIndicator(
progress = 0.5f,
shape = RoundedCornerShape(4.dp),
backgroundColor = Color(0xFFE4E4E4),
contentColor = Color(0xFF6699FF)
) {
ProgressBar()
}

Parameters

progress

The progress value between 0.0 and 1.0.

modifier

Modifier to be applied to the progress indicator.

shape

The shape of the progress indicator.

backgroundColor

The background color of the progress indicator.

contentColor

The color of the content.

content

The content of the progress indicator. For a batteries included component see ProgressBar.


fun ProgressIndicator(modifier: Modifier = Modifier, shape: Shape = RectangleShape, backgroundColor: Color = Color.Unspecified, contentColor: Color = LocalContentColor.current, content: @Composable () -> Unit)

A foundational component used to build progress indicators.

For interactive preview & code examples, visit Progress Indicator Documentation.

Basic Example

ProgressIndicator(
progress = 0.5f,
shape = RoundedCornerShape(4.dp),
backgroundColor = Color(0xFFE4E4E4),
contentColor = Color(0xFF6699FF)
) {
ProgressBar()
}

Parameters

modifier

Modifier to be applied to the progress indicator.

shape

The shape of the progress indicator.

backgroundColor

The background color of the progress indicator.

contentColor

The color of the content.

content

The content of the progress indicator.