cpr.geometry.Dimension
Geometry object that abstracts the width and height of the plane coordinate system.
Index
| Name |
Type |
Description |
| area |
Number |
Area. |
| height |
Number |
Height default 0 |
| width |
Number |
Width default 0 |
Constructor
Create a new width object.
| name |
type |
description |
| width
|
Number |
width. |
| height
|
Number |
Height. |
Properties
| type
|
Number |
| readonly
|
Area.
|
| type
|
Number |
|
Height default 0
|
| type
|
Number |
|
Width default 0
|
Methods
Expand the area.
| name |
type |
description |
| dimension
|
Dimension |
Width to expand. |
Expand the area.
| name |
type |
description |
| point
|
Point |
A point object with x and y values of the width of the area to be extended. |
Expand the area.
| name |
type |
description |
| width
|
Number |
Width to expand. |
| height
|
Number |
The height to extend. |
deprecatedPlease use add.
Expand by adding size.
deprecatedPlease use add.
Add point objects to expand their size.
| name |
type |
description |
| point
|
Point |
|
Compare for equality.
| name |
type |
description |
| obj
|
Object |
Object to be compared. |
| toleranceoptional
|
Number |
default0
|
tolerance. |
Returns a new object with its size expanded.
| name |
type |
description |
| point
|
Point |
|
Gets a copy object with the area expanded by the given size.
| name |
type |
description |
| dimension
|
Dimension |
The size to be expanded. |
Gets a copy object with the area expanded by the given size.
| name |
type |
description |
| dimension
|
Point |
The size to be expanded. |
Gets a copy object with the area expanded by the given size.
| name |
type |
description |
| width
|
Number |
Width to expand. |
| height
|
Number |
The height to extend. |
Returns a new object with its size expanded.
Create and return a new dimension with negative values.
It negates the width and height of this Dimension.