How do you add inner padding in compose? `padding`...
# compose
r
How do you add inner padding in compose?
padding
modifier only seems to add margin
1
s
Do you have a concrete example? If your case is that you have a background or border or something for your composable and then want some padding inside of that, then remember that modifier order matters.
Copy code
Modifier
  .padding(8.dp)
  .background(Color.White)
is different from
Copy code
Modifier
  .background(Color.White)
  .padding(8.dp)
The latter might be what you're looking for? simple smile
👍 3
r
Thank you, this was just what I was looking for
s
Perfect! Glad to help. simple smile