https://kotlinlang.org logo
#compose
Title
# compose
m

Mihai Hrincescu

10/17/2020, 9:12 PM
Hello, is the a way to get a
@Composable
to not get cliped by the parent? I already tried using
Modifier.drawLayer(clip = false)
but it seems to have no effect.
a

Adam Powell

10/17/2020, 9:14 PM
Only some composable layouts clip their children.
Surface
is one of them. Unless the parameters for that composable offer a way to change that setting, you cannot change it.
m

Mihai Hrincescu

10/17/2020, 9:52 PM
Well @Adam Powell the behaviour i was trying to achieve was a grid of selectable items in a card and when the user taps one of them it will get larger and expand beyond the bounds of the card. So there is no way to have a shape to define a card and also have a child of that
Composable
not be clipped by that shape unless i draw the card first and then grid on top instead of wrapping the grid with a card?
a

Adam Powell

10/17/2020, 9:53 PM
and definitely do file these things as feature requests! copy/paste like this and moving on is great for getting going again today, but this feedback is useful to us in terms of API changes before we reach beta to decide what the right tradeoffs are for the standard composables
m

Mihai Hrincescu

10/17/2020, 10:04 PM
Ok, I got it thx alot for the speedy answers @Adam Powell.
👍 1
4 Views