Colton Idle

09/05/2021, 2:34 AM
I have a column with horizontal padding
Copy code
Column(modifier = Modifier.padding(horizontal = 16.dp)) {
every item need the horizontal padding except for 1 item in the col. Is there an easy way to "opt out"?

Chris Johnson

09/05/2021, 3:22 AM
AFAIK there's no modifier that will just "do" that. You could just set the one item that needs to not have padding a negative offset of
but otherwise the solution would get more complex. I.e maybe a custom layout?
👍 1

Will Shelor

09/05/2021, 4:50 AM
You could also create a base Modifier object, but instead of passing it to the column pass it to the children of the column except for the one that does not need the padding