Creates and returns an CAConstraint object with the specified parameters.
Original signature is '+ (id)constraintWithAttribute:(CAConstraintAttribute)attr relativeTo:(NSString *)srcLayer attribute:(CAConstraintAttribute)srcAttr scale:(CGFloat)scale offset:(CGFloat)offset'
Available in Mac OS X v10.5 and later.
Declaration Syntax
C# | Visual Basic | Visual C++ |
public static CAConstraint ConstraintWithAttributeRelativeToAttributeScaleOffset( CAConstraintAttribute attr, NSString srcLayer, CAConstraintAttribute srcAttr, CGFloat scale, CGFloat offset )
Public Shared Function ConstraintWithAttributeRelativeToAttributeScaleOffset ( _ attr As CAConstraintAttribute, _ srcLayer As NSString, _ srcAttr As CAConstraintAttribute, _ scale As CGFloat, _ offset As CGFloat _ ) As CAConstraint
public: static CAConstraint^ ConstraintWithAttributeRelativeToAttributeScaleOffset( CAConstraintAttribute attr, NSString^ srcLayer, CAConstraintAttribute srcAttr, CGFloat scale, CGFloat offset )
Parameters
- attr (CAConstraintAttribute)
- The attribute of the layer for which to create a new constraint.
- srcLayer (NSString)
- The name of the layer that this constraint is calculated relative to.
- srcAttr (CAConstraintAttribute)
- The attribute of srcLayer the constraint is calculated relative to.
- scale (CGFloat)
- The amount to scale the value of srcAttr.
- offset (CGFloat)
- The offset from the srcAttr.
Return Value
A new CAConstraint object with the specified parameters.
Version Information
- Available in Monobjc Bridge: 10.6 (For Mac OS X 10.6 and later), 10.5 (For Mac OS X 10.5 and later)