from model.errors import WrongNumberOfArguments
class Arc():
+ """Interface for editing a sketch arc feature."""
def __init__(self, arc_feature, *args):
self._feature = arc_feature
self._center = geomDataAPI_Point2D(
"Arc takes 3 or 6 arguments (%s given)" % len(args)
)
- def centerData (self):
+ def centerData(self):
+ """Return the center point data."""
return self._center
- def startPointData (self):
+ def startPointData(self):
+ """Return the start point data."""
return self._start_point
- def endPointData (self):
+ def endPointData(self):
+ """Return the end point data."""
return self._end_point
- def result (self):
+ def result(self):
+ """Return the arc circular line attribute."""
return self._feature.lastResult()
########
#
########
- def __createByCoordinates(self,
- center_x, center_y,
- start_x, start_y,
- end_x, end_y):
+ def __createByCoordinates(self, center_x, center_y,
+ start_x, start_y,
+ end_x, end_y):
"""Create an arc by point coordinates."""
self._center.setValue(center_x, center_y)
self._start_point.setValue(start_x, start_y)