weight

abstract fun Modifier.weight(weight: Float = 1.0f): Modifier

Gives this child a share of the width left over after the unweighted children. Unlike RowScope.weight, it does not make the toolbar fill the width it was offered: a weighted child stretches when the caller fixed the toolbar's width (so trailing items stay pinned to the far edge of a full-bleed bar) and shrinks to its content when the toolbar is wrapping (so a floating toolbar is exactly as wide as its icons). The item row's default.