def setSVG(self): attr = PositionableElement.setSVG(self) point1 = V(self.point1.x + self.x, self.point1.y + self.y) point2 = V(self.point2.x + self.x, self.point2.y + self.y) self.applyTransform(point1, point2) attr.update([('x1', point1.x), ('y1', point1.y), ('x2', point2.x), ('y2', point2.y)]) return attr
def setSVG (self): pos = V (self.x, self.y) self.applyTransform (pos) attr = PositionableElement.setSVG (self) attr.update ([('cx', pos.x), ('cy', pos.y), ('r', self.radius)]) return attr
def setSVG (self): attr = PositionableElement.setSVG (self) point1 = V (self.point1.x + self.x, self.point1.y + self.y) point2 = V (self.point2.x + self.x, self.point2.y + self.y) self.applyTransform (point1, point2) attr.update ([('x1', point1.x), ('y1', point1.y), ('x2', point2.x), ('y2', point2.y)]) return attr
def setSVG(self): attr = PositionableElement.setSVG(self) pos = V(self.x, self.y) o = pos p1 = self.point1 + pos p2 = self.point2 + pos self.applyTransform(o, p1, p2) d1 = 'M ' + str(o) d2 = 'L ' + str(p1) d3 = 'A ' + str(self.radius) + ' ' + str(self.radius) + ' 1 0 0 ' d3 += str(p2) d4 = 'Z' data = ' '.join([d1, d2, d3, d4]) attr.update([('d', data)]) return attr
def setSVG (self): attr = PositionableElement.setSVG (self) pos = V (self.x, self.y) o = pos p1 = self.point1 + pos p2 = self.point2 + pos self.applyTransform (o, p1, p2) d1 = 'M ' + str (o) d2 = 'L ' + str (p1) d3 = 'A ' + str(self.radius) + ' ' + str(self.radius) + ' 1 0 0 ' d3 += str(p2) d4 = 'Z' data = ' '.join ([d1, d2, d3, d4]) attr.update ([('d', data)]) return attr