diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 00000000..1649e864 Binary files /dev/null and b/.DS_Store differ diff --git a/examples/.DS_Store b/examples/.DS_Store new file mode 100644 index 00000000..9c8fb76d Binary files /dev/null and b/examples/.DS_Store differ diff --git a/examples/SVG Import/Clipping.html b/examples/SVG Import/Clipping.html index 46e4eddc..238227c7 100644 --- a/examples/SVG Import/Clipping.html +++ b/examples/SVG Import/Clipping.html @@ -5,97 +5,105 @@ Clipping - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Clipping a path with a path: - Clipping a compound path with a path: - Clipping a path with a compound path: - Clipping a group with a path: + + + + + + + + + + - - - + - - - - - - - - - - - + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Clipping a path with a path: +Clipping a compound path with a path: +Clipping a path with a compound path: +Clipping a group with a path: + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/examples/SVG Import/Multiple Paths Test 1.html b/examples/SVG Import/Multiple Paths Test 1.html index 3afaa70c..8a1b37fa 100644 --- a/examples/SVG Import/Multiple Paths Test 1.html +++ b/examples/SVG Import/Multiple Paths Test 1.html @@ -11,31 +11,57 @@ - - - - - - - - - - - - - - - - - - - - - - - - - I love SVG + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/svg/SvgImport.js b/src/svg/SvgImport.js index c2076373..61252ba9 100644 --- a/src/svg/SvgImport.js +++ b/src/svg/SvgImport.js @@ -61,6 +61,13 @@ new function() { } } } + + if (type == 'defs') { + // I don't think we need to add defs to the DOM. But we might want + // to use Symbols for them? + group.remove(); + grourp = null; + } return group; } @@ -206,12 +213,7 @@ new function() { }, // http://www.w3.org/TR/SVG/struct.html#DefsElement - defs: function(svg, type) { - var group = importGroup(svg, type); - group.remove(); - // I don't think we need to add defs to the DOM. But we might want - // to use Symbols for them? - return null; + defs: importGroup, }, // http://www.w3.org/TR/SVG/shapes.html#InterfaceSVGCircleElement