]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Small formatting and fix of addCircle
authorspo <sergey.pokhodenko@opencascade.com>
Tue, 14 Jun 2016 10:06:12 +0000 (13:06 +0300)
committerspo <sergey.pokhodenko@opencascade.com>
Fri, 17 Jun 2016 11:41:06 +0000 (14:41 +0300)
src/SketchAPI/SketchAPI_Sketch.cpp
src/SketchAPI/SketchAPI_Sketch.h

index ea8047d6c17fa670350da5fecebb8204e051e233..c0bdae5e882e34f3f60e2c16786836aec20de1cf 100644 (file)
@@ -162,14 +162,14 @@ std::shared_ptr<SketchAPI_Circle> SketchAPI_Sketch::addCircle(const std::shared_
 
 std::shared_ptr<SketchAPI_Circle> SketchAPI_Sketch::addCircle(const ModelHighAPI_Selection & theExternal)
 {
-  std::shared_ptr<ModelAPI_Feature> aFeature = compositeFeature()->addFeature(SketchPlugin_Line::ID());
+  std::shared_ptr<ModelAPI_Feature> aFeature = compositeFeature()->addFeature(SketchPlugin_Circle::ID());
   return CirclePtr(new SketchAPI_Circle(aFeature, theExternal));
 }
 
 std::shared_ptr<SketchAPI_Circle> SketchAPI_Sketch::addCircle(const std::string & theExternalName)
 {
   // TODO(spo): Add constraint SketchConstraintRigid like in PythonAPI. Is it necessary?
-  std::shared_ptr<ModelAPI_Feature> aFeature = compositeFeature()->addFeature(SketchPlugin_Line::ID());
+  std::shared_ptr<ModelAPI_Feature> aFeature = compositeFeature()->addFeature(SketchPlugin_Circle::ID());
   return CirclePtr(new SketchAPI_Circle(aFeature, theExternalName));
 }
 
index 524c013c435a31ec4f56998ce0bfc07eef6f1529..3dce93862620252a67699b1595051812d7947eb7 100644 (file)
@@ -81,34 +81,32 @@ public:
   SKETCHAPI_EXPORT
   std::shared_ptr<SketchAPI_Line> addLine(const std::string & theExternalName);
 
-  // Add circle.
-  SKETCHAPI_EXPORT
-  std::shared_ptr<SketchAPI_Circle> addCircle(double theCenterX,
-                                              double theCenterY,
-                                              double theRadius);
-
-  // Add circle.
-  SKETCHAPI_EXPORT
-  std::shared_ptr<SketchAPI_Circle> addCircle(const std::shared_ptr<GeomAPI_Pnt2d>& theCenter,
-                                              double theRadius);
-
-  // Add circle.
-  SKETCHAPI_EXPORT
-  std::shared_ptr<SketchAPI_Circle> addCircle(double theX1, double theY1,
-                                              double theX2, double theY2,
-                                              double theX3, double theY3);
-
-  // Add circle.
-  SKETCHAPI_EXPORT
-  std::shared_ptr<SketchAPI_Circle> addCircle(const std::shared_ptr<GeomAPI_Pnt2d>& thePoint1,
-                                              const std::shared_ptr<GeomAPI_Pnt2d>& thePoint2,
-                                              const std::shared_ptr<GeomAPI_Pnt2d>& thePoint3);
-
-  /// Add circle.
+  /// Add circle
+  SKETCHAPI_EXPORT
+  std::shared_ptr<SketchAPI_Circle> addCircle(
+      double theCenterX, double theCenterY,
+      double theRadius);
+  /// Add circle
+  SKETCHAPI_EXPORT
+  std::shared_ptr<SketchAPI_Circle> addCircle(
+      const std::shared_ptr<GeomAPI_Pnt2d>& theCenter,
+      double theRadius);
+  /// Add circle
+  SKETCHAPI_EXPORT
+  std::shared_ptr<SketchAPI_Circle> addCircle(
+      double theX1, double theY1,
+      double theX2, double theY2,
+      double theX3, double theY3);
+  /// Add circle
+  SKETCHAPI_EXPORT
+  std::shared_ptr<SketchAPI_Circle> addCircle(
+      const std::shared_ptr<GeomAPI_Pnt2d>& thePoint1,
+      const std::shared_ptr<GeomAPI_Pnt2d>& thePoint2,
+      const std::shared_ptr<GeomAPI_Pnt2d>& thePoint3);
+  /// Add circle
   SKETCHAPI_EXPORT
   std::shared_ptr<SketchAPI_Circle> addCircle(const ModelHighAPI_Selection & theExternal);
-
-  /// Add circle.
+  /// Add circle
   SKETCHAPI_EXPORT
   std::shared_ptr<SketchAPI_Circle> addCircle(const std::string & theExternalName);