--- a/linetypes.py Sun Dec 10 15:37:26 2017 +0200 +++ b/linetypes.py Sun Dec 10 15:45:50 2017 +0200 @@ -44,3 +44,14 @@ class Quadrilateral(LineSegment): pass + +class Contour(LineSegment): + def __init__(self, *, color, geometry, control_points): + super().__init__(color = color, geometry = geometry) + self.control_points = control_points + assert(len(self.control_points) == 2) + def __repr__(self): + return str.format('linetypes.Contour(' \ + 'color = {color!r}, ' \ + 'geometry = {geometry!r}, ' \ + 'control_points = {control_points!r})', **self.__dict__)