]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Correct deflection coefficient for sketch editing mode
authorvsv <vitaly.smetannikov@opencascade.com>
Tue, 17 Nov 2015 14:27:34 +0000 (17:27 +0300)
committervsv <vitaly.smetannikov@opencascade.com>
Tue, 17 Nov 2015 14:27:45 +0000 (17:27 +0300)
src/ModuleBase/ModuleBase_Tools.cpp
src/ModuleBase/ModuleBase_Tools.h

index 889da3e0e7fa8d9941e5526b7a64c3299d612e99..7c9fced2b12acf88f2c79c362310e5d9e69f4d57 100755 (executable)
@@ -258,7 +258,10 @@ void checkObjects(const QObjectPtrList& theObjects, bool& hasResult, bool& hasFe
 void setDefaultDeviationCoefficient(const TopoDS_Shape& theShape,
                                     const Handle(Prs3d_Drawer)& theDrawer)
 {
-  if (!theShape.IsNull() && theShape.ShapeType() == TopAbs_EDGE)
+  if (theShape.IsNull())
+    return;
+  TopAbs_ShapeEnum aType = theShape.ShapeType();
+  if ((aType == TopAbs_EDGE) || (aType == TopAbs_WIRE)) 
     theDrawer->SetDeviationCoefficient(1.e-4);
 }
 
index f78e9b7550a627306754dd9469fbf0aee16f67c5..8c2a00db188d014b7a4df066bea842537de278d3 100755 (executable)
@@ -108,7 +108,7 @@ MODULEBASE_EXPORT void checkObjects(const QObjectPtrList& theObjects, bool& hasR
 /*! Sets the default coeffient into the driver calculated accordingly the shape type.
 It provides 1.e-4 for a shape withe Edge shape type
 \param theShape a shape to define the deviation coeffient, 
-\return double value
+\param theDrawer a drawer
 */
 MODULEBASE_EXPORT void setDefaultDeviationCoefficient(const TopoDS_Shape& theShape,
                                                       const Handle(Prs3d_Drawer)& theDrawer);