Function

constrainHeight

Constrains a given height value to fit within the bounds of this VolumeConstraints object.

constrainHeight

Source set: Android
public fun VolumeConstraints.constrainHeight(height: Int): Int

Constrains a given height value to fit within the bounds of this VolumeConstraints object.

Parameters

height the height value to constrain.

Return

the constrained height value, ensuring it's within the minimum and maximum height bounds.

Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: