Thanx to <@UJT6PRXB9> on his help to find an inter...
# compose
r
Thanx to @Mihai Popa on his help to find an intermediate solution until modifier can be spiced with Align.CenterVertically in dev04 or so... Here's his neat solution using
MaxIntrinsicHeight
and a
Column
with
ExpandedHeight
wrapping a
Container
modifying
Gravity.End wraps ExpandedHeight
to achieve "Center End" alignment in the remaining space !!
Copy code
@Composable
fun CardGravityTest2()
{
    Card(
            modifier = Spacing(all = 4.dp),
            color = Color.LightGray,
            shape = RoundedCornerShape(
                    size = 5.dp
            )
    ){
        Column {

            MaxIntrinsicHeight {
                Row {
                    Surface(
                            color = Color.Red,
                            modifier = Spacing(all = 4.dp)
                    ) {
                        Text(text = "1 Surface")
                    }

                    Column(
                            modifier = Flexible(
                                    flex = 1f
                            ) wraps Spacing(
                                    all = 4.dp
                            )
                    ) {
                        Surface(
                                color = Color.Green
                        ) {
                            Text(text = "2 Column mod Flexible wraps Spacing," +
                                    "Surface no mod ")
                        }
                        Surface(
                                color = Color.Magenta
                        ){
                            Text(text = "3 Surface no mod ")
                        }
                    }

                    Column (modifier = ExpandedHeight) {

                        Surface(
                                modifier = Gravity.End,
                                color = Color.DarkGray
                        ){
                            Text(text = "4. Col no mod, Srf Gr.end")
                        }

                        Container(modifier = Gravity.End wraps ExpandedHeight) {
                            Surface(
                                    color = Color.Yellow
                            ){
                                Text(text = "5. Center End !! ")
                            }
                        }
                    }
                }
            }
        }
    }
}