new Rectangle(x, y, width, height)
sdk/core/lib/math/rectangle.js, line 31
Creartes a Rectangle
Name | Type | Default | Description |
---|---|---|---|
x |
Number | 0 | optional |
y |
Number | 0 | optional |
width |
Number | 0 | optional |
height |
Number | 0 | optional |
Methods
-
clone(){PhotoEditorSDK.Math.Rectangle}
sdk/core/lib/math/rectangle.js, line 56 -
Creates a clone of this rectangle
Returns:
Type Description PhotoEditorSDK.Math.Rectangle -
copy(other){PhotoEditorSDK.Math.Rectangle}
sdk/core/lib/math/rectangle.js, line 65 -
Copies the values of the given rectangle
Name Type Description other
PhotoEditorSDK.Math.Rectangle Returns:
Type Description PhotoEditorSDK.Math.Rectangle -
equals(rect, y, width, height){Boolean}
sdk/core/lib/math/rectangle.js, line 81 -
Checks whether this rectangle's values are the same as the given ones
Name Type Description rect
Number | PhotoEditorSDK.Math.Rectangle y
Number width
Number height
Number Returns:
Type Description Boolean -
round(){PhotoEditorSDK.Math.Rectangle}
sdk/core/lib/math/rectangle.js, line 126 -
Rounds this rectangle's values
Returns:
Type Description PhotoEditorSDK.Math.Rectangle -
set(x, y){PhotoEditorSDK.Math.Rectangle}
sdk/core/lib/math/rectangle.js, line 44 -
Sets the given values
Name Type Description x
Number y
Number Returns:
Type Description PhotoEditorSDK.Math.Rectangle -
toString(){String}
sdk/core/lib/math/rectangle.js, line 170 -
Returns a string representation of this rectangle
Returns:
Type Description String