Relative Content

Tag Archive for androidandroid-jetpack-composeandroid-compose-layoutandroid-jetpack-compose-button

How do I make a Text composable take up x% of the Row’s width when there’s a IconButton in the row?

I have a Row which has an IconButton on the left, then 16dp padding, then a Text that takes up the remaining width in the Row, then finally on the right, another Text which should take up 25% of the width of the Row. Everything works except that the second Text is actually taking up 25% of the width of the Row, excluding the width of the IconButton. This makes the second Text’s width too thin.