# compose

Billy Newman

08/09/2022, 5:11 PM
Hello all, having problems trying to set the height of a Row to the full height based on its childrens height. If you can take a peek, thanks in advance. Code in comments
Copy code
Row {

   Column {
         pagerState = pagerState,
         modifier = Modifier
            .padding(bottom = 16.dp),

         count = mapAnnotations.size,
         state = pagerState,
         contentPadding = PaddingValues(horizontal = 0.dp),
         modifier = Modifier.fillMaxWidth(),
      ) { page ->
            modifier = Modifier
         ) {
However I am not seeing the Box with the black background. This is in a bottom sheet and if I set the height to fillMaxHeight() the height is much taller than the content. Not sure why
Copy code
is not working

Landry Norris

08/09/2022, 6:22 PM
What happens if you use IntrinsicSize.Max? The min size should be 0 for the box, right?
Or you could use fillMaxHeight on the Box like the divider in

Billy Newman

08/09/2022, 6:41 PM
InstristicSize.Max does not seem to make a difference. And the problem with using fillMaxHeight on the Box is that the max height of the parent (since it is a bottom sheet) is much bigger than the size of the content the children take up.
Fairly certain my issue form checking the docs is that the IntrinsicSize.Min needs to be on the top level Row, since that contains the children with dynamic height. However when doing that I get the following error message:
Asking for intrinsic measurements of SubcomposeLayout layouts is not supported.

Tin Tran

08/10/2022, 4:21 AM
Currently this is not supported. You need to write your custom layout to measure the children and set the parent height accordingly