Dovydas
02/19/2025, 12:37 PMFlorinda Hasani
02/19/2025, 1:24 PMStylianos Gakis
02/19/2025, 1:33 PMDovydas
02/19/2025, 5:24 PMStylianos Gakis
02/19/2025, 5:58 PM.weight(1f).wrapContentHeight(alignment...)
And it will fill the rest of the height and then align itself according to whatever alignment you decide to pass in there.Dovydas
02/20/2025, 7:39 AMStylianos Gakis
02/20/2025, 8:19 AMArne Jans
03/04/2025, 8:17 AMweight
in a LazyColum
directly, as the always-scrollable LazyColumn manages infinite space in the lazy direction (and its content is not Composable but item
or items
). But for your item
-Composable-content in the LazyColumn, you can use weight, as long as it does not weight-measure with unlimited space in the infinite direction.
So e.g. you can use weight
in a Column
that is in the LazyColumn
, but then you have to set a fixed height
to the column. Then you can use the weight
-modifier for the Composables in the Column.
It always comes down to the parent-Composable constraining the min-size and the max-size of the child-Composables (or in the context of LazyList, not constraining...).