Methods
(static) _setOptions(optionsopt)
Sets object's properties from options
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
options |
Object |
<optional> |
Options object |
(static) get(property) → {*}
Basic getter
Parameters:
Name | Type | Description |
---|---|---|
property |
String | Property name |
Returns:
value of a property
- Type
- *
(static) set(key, value) → {fabric.Object}
Sets property to a given value. When changing position/dimension -related properties (left, top, scale, angle, etc.) `set` does not update position of object's borders/controls. If you need to update those, call `setCoords()`.
Parameters:
Name | Type | Description |
---|---|---|
key |
String | Object | Property name or object (if object, iterate over the object properties) |
value |
Object | function | Property value (if function, the value is passed into it and its return value is used as a new one) |
Returns:
thisArg
- Type
- fabric.Object
(static) toggle(property) → {fabric.Object}
Toggles specified property from `true` to `false` or from `false` to `true`
Parameters:
Name | Type | Description |
---|---|---|
property |
String | Property to toggle |
Returns:
thisArg
- Type
- fabric.Object