对于同一视图/对象中的不同属性,使用swiftUI可以进行不同的.animation缓解。例如,如果我有一个圆(),我可以用不同于.rotationEffect的缓动效果来制作.trim动画吗?
Circle()
.trim(from: 0.0, to: myProgress)
.rotationEffect(Angle.degrees(myRot))
.animation(.easeIn)
发布于 2020-09-30 02:13:33
看起来你可以做到
Circle()
.trim(from: 0.0, to: myProgress)
.animation(.easeOut)
.rotationEffect(Angle.degrees(myRot))
.animation(.easeIn)
.position(myPos)
.animation(nil)
并且每个.animation只影响它上面的内容
https://stackoverflow.com/questions/64125238
复制相似问题