]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/PythonAPI/model/sketcher/point.py
Salome HOME
[PythonAPI / sketcher] Added methods for sketch features modification
[modules/shaper.git] / src / PythonAPI / model / sketcher / point.py
index 69b9f88fcd8b3a0aafc64467a1a3845e1a01e50c..3a65acea54df7db4f367652ae2bade242e00c359 100644 (file)
@@ -14,15 +14,12 @@ class Point(Interface):
         self._point_data = geomDataAPI_Point2D(
             self._feature.data().attribute("PointCoordinates")
             )
+        self.setValue(x, y)
+        self._execute()
+
+    def setValue(self, x, y):
+        """Set point coordinates."""
         self._point_data.setValue(x, y)
-        
-        # Control input and execute
-        if self.areInputValid():
-            self.execute()
-        else:
-            raise FeatureInputInvalid(
-                "cannot create the Sketch Point, the input is invalid"
-                )
 
     def pointData (self):
         """Return the point data."""