Fix issue with cloning gradient colors.
Handle importing of SVG gradients for shapes, and drawing of canvas gradients correctly.

Closes #312.