Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
897 views
in Technique[技术] by (71.8m points)

core animation - What is the full Keypath list for CABasicAnimation?

I've looked in the documentation but I noticed it's missing some like "transform.scale.xy": [CoreAnimation Guide][1] is there a more complete list?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Here's everything I'm aware of in terms of animatable properties, keyPaths, and key-value coding extensions.

CALayer Animatable layer properties -- the other CALayer types below all inherit from CALayer, so these also apply to those:

anchorPoint
backgroundColor
backgroundFilters
borderColor
borderWidth
bounds
compositingFilter
contents
contentsRect
cornerRadius
doubleSided
filters
frame
hidden
mask
masksToBounds
opacity
position
shadowColor
shadowOffset
shadowOpacity
shadowPath
shadowRadius
sublayers
sublayerTransform
transform
zPosition

CAEmitterLayer animatable properties:

emitterPosition
emitterZPosition
emitterSize

CAGradientLayer animatable properties:

colors
locations
endPoint
startPoint

CAReplicatorLayer animatable properties:

instanceDelay
instanceTransform
instanceRedOffset
instanceGreenOffset
instanceBlueOffset
instanceAlphaOffset

CAShapeLayer animatable properties:

fillColor
lineDashPhase
lineWidth
miterLimit
strokeColor
strokeStart
strokeEnd

CATextLayer animatable properties:

fontSize
foregroundColor

CATiledLayer animatable properties:

I feel like tileSize is animatable, but documentation doesn't agree.

CATransform3D Key-Value Coding Extensions:

rotation.x
rotation.y
rotation.z
rotation
scale.x
scale.y
scale.z
scale
translation.x
translation.y
translation.z

CGPoint keyPaths:

x
y

CGSize keyPaths:

width
height

CGRect keyPaths:

origin
origin.x
origin.y
size
size.width
size.height

These are Appendix B of the Core Animation Programming Guide, and Appendix C of the same.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...