Packagexp.graphics
Classpublic class CornerRadius

CornerRadius is a value type used to describe the radius of a rectangle's corners (controlled independently). It contains four number structs each corresponding to a corner: TopLeft, TopRight, BottomLeft, BottomRight. The corner radii cannot be negative.

See also

support


Public Properties
 PropertyDefined by
  bottomLeft : Number = 0
CornerRadius
  bottomRight : Number = 0
CornerRadius
  CornerRadius0 : CornerRadius
[static]
CornerRadius
  CornerRadius3 : CornerRadius
[static]
CornerRadius
  topLeft : Number = 0
CornerRadius
  topRight : Number = 0
CornerRadius
Public Methods
 MethodDefined by
  
CornerRadius(... rest)
CornerRadius
  
clone():Object
Returns a new CornerRadius object with the same values for the topLeft, topRight, bottomRight, and bottomLeft properties as the original CornerRadius object.
CornerRadius
  
copy(target:CornerRadius):void
Changes this CornerRadius object to match the same values for the topLeft, topRight, bottomRight, and bottomLeft properties as the target CornerRadius object.
CornerRadius
  
hasSimpleRadius():Boolean
CornerRadius
  
isEmpty():Boolean
CornerRadius
  
setEmpty():void
Sets all of the CornerRadius object's properties to 0.
CornerRadius
  
setRadius(topLeft:Number, topRight:Number, bottomRight:Number, bottomLeft:Number):void
Set the properties of this CornerRadiusobject
CornerRadius
Property detail
bottomLeftproperty
public var bottomLeft:Number = 0
bottomRightproperty 
public var bottomRight:Number = 0
CornerRadius0property 
public static var CornerRadius0:CornerRadius
CornerRadius3property 
public static var CornerRadius3:CornerRadius
topLeftproperty 
public var topLeft:Number = 0
topRightproperty 
public var topRight:Number = 0
Constructor detail
CornerRadius()constructor
public function CornerRadius(... rest)Parameters
... rest
Method detail
clone()method
public function clone():Object

Returns a new CornerRadius object with the same values for the topLeft, topRight, bottomRight, and bottomLeft properties as the original CornerRadius object.

Returns
Object — A new CornerRadius object with the same values for the topLeft, topRight, bottomRight, and bottomLeft properties as the original CornerRadius object.
copy()method 
public function copy(target:CornerRadius):void

Changes this CornerRadius object to match the same values for the topLeft, topRight, bottomRight, and bottomLeft properties as the target CornerRadius object.

Parameters
target:CornerRadius
hasSimpleRadius()method 
public function hasSimpleRadius():Boolean

Returns
Boolean
isEmpty()method 
public function isEmpty():Boolean

Returns
Boolean
setEmpty()method 
public function setEmpty():void

Sets all of the CornerRadius object's properties to 0. A CornerRadius object is empty if all its corner radius is equal to 0. This method sets the values of the topLeft, topRight, bottomRight, and bottomLeft properties to 0.

setRadius()method 
public function setRadius(topLeft:Number, topRight:Number, bottomRight:Number, bottomLeft:Number):void

Set the properties of this CornerRadiusobject

Parameters
topLeft:Number
 
topRight:Number
 
bottomRight:Number
 
bottomLeft:Number