Colton Idle
12/14/2021, 9:13 PMBox(
modifier.fillMaxWidth().graphicsLayer {
scaleY = 1000f
clip = false
},
Is there a way to prevent this clipping? I thought compose didn't clip by default? Even if it did, I thought clipToBounds() would allow me to pass in "false" but it does not.Andrey Kulikov
12/15/2021, 5:23 PMNader Jawad
12/15/2021, 6:18 PMNader Jawad
12/15/2021, 8:02 PMColton Idle
12/15/2021, 8:51 PMColton Idle
12/15/2021, 8:52 PMBox(
modifier.fillMaxWidth().graphicsLayer {
rotationY = rotation
clip = false
cameraDistance = 4 * density
},
contentAlignment = Alignment.Center) {
MyCreditCardComposable(
Colton Idle
12/15/2021, 8:53 PMNader Jawad
12/15/2021, 9:09 PMNader Jawad
12/15/2021, 9:23 PMit is recommended to always use a camera distance that's greater than the height (X axis rotation) or the width (Y axis rotation) of this view.
Colton Idle
12/15/2021, 11:18 PMNader Jawad
12/15/2021, 11:23 PM4*density
Nader Jawad
12/15/2021, 11:23 PMColton Idle
12/15/2021, 11:37 PMColton Idle
12/15/2021, 11:45 PMColumn(horizontalAlignment = Alignment.CenterHorizontally) {
BoxWithConstraints() {
val boxScope = this
MyCreditCard(
modifier =
Modifier
.graphicsLayer {
rotationX = bottomSheetProgress.value * 20
cameraDistance = boxScope.maxWidth.value
})
}
Box(modifier = Modifier.background(Color.Green).size(100.dp)) {
//
}
}