--- a/svg2gcode/svg/svg.py Sun Nov 08 04:18:58 2015 +0100 +++ b/svg2gcode/svg/svg.py Sun Nov 08 05:03:45 2015 +0100 @@ -248,6 +248,10 @@ def __init__(self, elt=None): Transformable.__init__(self, elt) + if elt is not None: + self.style = elt.get('style') + else: + self.style = '' def append(self, element): for elt in element: @@ -261,6 +265,10 @@ item.matrix = self.matrix * item.matrix item.viewport = self.viewport + # inherit style from group + if item.style == '': + item.style = self.style + self.items.append(item) # Recursively append if elt is a <g> (group) if elt.tag == svg_ns + 'g':