]> SALOME platform Git repositories - modules/shaper.git/blob - src/PythonAPI/modeler/sketcher/point.py
Salome HOME
acd88be81d46496e3fac94ccaa7e982277368695
[modules/shaper.git] / src / PythonAPI / modeler / sketcher / point.py
1 # Class definitions of Sketch features
2
3 from GeomDataAPI import geomDataAPI_Point2D
4
5 class Point():
6
7   def __init__(self, sketch, x, y):
8     self.my = sketch.addFeature("SketchPoint")
9     geomDataAPI_Point2D( self.my.data().attribute("PointCoordindates") ).setValue(x, y)
10     self.my.execute()
11
12   def pointData (self):
13     return geomDataAPI_Point2D( self.my.data().attribute("PointCoordindates") )
14
15   def result (self):
16     return self.my.firstResult()