diff options
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 13 |
1 files changed, 12 insertions, 1 deletions
@@ -443,6 +443,12 @@ var ellipse = draw.ellipse(80, 40).move(10, 10).fill({ color: gradient.fill() }) rect.maskWith(ellipse); ``` +For your convenience, the masking element is also referenced in the masked element. This would be useful in case you want to change, or remove the mask: + +```javascript +rect.mask.remove(); +``` + _This functionality requires the mask.js module which is included in the default distribution._ @@ -627,6 +633,12 @@ rect.click(function() { }); ``` +Removing it is quite as easy: + +```javascript +rect.click(null); +``` + You can also bind event listeners to elements: ```javascript @@ -733,7 +745,6 @@ Here are a few nice plugins that are available for svg.js: - [svg.draggable.js](https://github.com/wout/svg.draggable.js) to make elements draggable. - ## Building Starting out with the default distribution of svg.js is good. Although you might want to remove some modules to keep the size at minimum. |