Mehdi Haghgoo
08/02/2021, 10:46 AMRow(Modifier.fillMaxSize().background(Color.Yellow)) {
val pics = listOf(R.drawable.professor, R.drawable.woman,
R.drawable.daughter, R.drawable.son)
for (pic in pics)
Image(painterResource(id = pic), null, Modifier.fillMaxWidth(0.25f).align(Alignment.Bottom))
}
Mehdi Haghgoo
08/02/2021, 10:52 AMAlbert Chang
08/02/2021, 10:55 AMModifier.fillMaxWidth()
is relative to the current available width, which means the widths of your images are 0.25, 0.1875 and so on. You should use Modifier.weight(1f)
here.