132 class polycommon(svgshape): |
132 class polycommon(svgshape): |
133 |
133 |
134 def __init__(self, xml_node, polytype): |
134 def __init__(self, xml_node, polytype): |
135 super(polycommon, self).__init__(xml_node) |
135 super(polycommon, self).__init__(xml_node) |
136 self.points = list() |
136 self.points = list() |
137 |
|
138 if not self.xml_node == None: |
137 if not self.xml_node == None: |
139 polycommon_el = self.xml_node |
138 polycommon_el = self.xml_node |
140 points = polycommon_el.get('points') if polycommon_el.get('points') else list() |
139 points = polycommon_el.get('points') if polycommon_el.get('points') else list() |
141 points = points.split() |
140 points = points.split() |
142 for pa in points: |
141 for pa in points: |
143 self.points.append(pa) |
142 self.points.append(pa) |
144 #if polycommon_el.get('fill'): |
|
145 # # Append first point to close shape |
|
146 # self.points.append(points[0]) |
|
147 else: |
143 else: |
148 logging.error("polycommon: Unable to get the attributes for %s", self.xml_node) |
144 logging.error("polycommon: Unable to get the attributes for %s", self.xml_node) |
149 |
145 |
150 |
146 |
151 class polygon(polycommon): |
147 class polygon(polycommon): |