From 41724cd29b1feb9f0a810bbc36a12c11fe3d1263 Mon Sep 17 00:00:00 2001 From: David Osterberg Date: Tue, 16 Feb 2021 07:55:20 +0100 Subject: [PATCH] PartDesign: Hole: Rename Automatic Tapped (DIN76) and change default to Hole depth. --- src/Mod/PartDesign/App/FeatureHole.cpp | 6 +++--- src/Mod/PartDesign/Gui/TaskHoleParameters.ui | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Mod/PartDesign/App/FeatureHole.cpp b/src/Mod/PartDesign/App/FeatureHole.cpp index b9fd0df5b5..df5b790178 100644 --- a/src/Mod/PartDesign/App/FeatureHole.cpp +++ b/src/Mod/PartDesign/App/FeatureHole.cpp @@ -76,7 +76,7 @@ namespace PartDesign { /* TRANSLATOR PartDesign::Hole */ const char* Hole::DepthTypeEnums[] = { "Dimension", "ThroughAll", /*, "UpToFirst", */ NULL }; -const char* Hole::ThreadDepthTypeEnums[] = { "Automatic", "Dimension", "Hole Depth", NULL }; +const char* Hole::ThreadDepthTypeEnums[] = { "Hole Depth", "Dimension", "Tapped (DIN76)", NULL }; const char* Hole::ThreadTypeEnums[] = { "None", "ISOMetricProfile", "ISOMetricFineProfile", "UNC", "UNF", "UNEF", NULL}; const char* Hole::ClearanceMetricEnums[] = { "Standard", "Close", "Wide", NULL}; const char* Hole::ClearanceUTSEnums[] = { "Normal", "Close", "Loose", NULL }; @@ -1000,7 +1000,7 @@ void Hole::updateThreadDepthParam() throw Base::RuntimeError("Unsupported depth type \n"); } - if ( std::string(ThreadDepthType.getValueAsString()) == "Automatic" ) { + if ( std::string(ThreadDepthType.getValueAsString()) == "Tapped (DIN76)" ) { ThreadDepth.setValue(Depth.getValue() - getThreadRunout()); } else { // hole depth ThreadDepth.setValue(Depth.getValue()); @@ -1872,7 +1872,7 @@ App::DocumentObjectExecReturn *Hole::execute(void) threadDepth = length; ThreadDepth.setValue(threadDepth); helixLength = threadDepth + 2*P; - } else if ( threadDepthMethod == "Automatic" ) { + } else if ( threadDepthMethod == "Tapped (DIN76)" ) { threadDepth = Depth.getValue() - getThreadRunout(); ThreadDepth.setValue(threadDepth); helixLength = threadDepth + P/2; diff --git a/src/Mod/PartDesign/Gui/TaskHoleParameters.ui b/src/Mod/PartDesign/Gui/TaskHoleParameters.ui index b74ff5db82..f0afe5bed8 100644 --- a/src/Mod/PartDesign/Gui/TaskHoleParameters.ui +++ b/src/Mod/PartDesign/Gui/TaskHoleParameters.ui @@ -435,7 +435,7 @@ Only available for holes without thread - Automatic + Hole depth @@ -445,7 +445,7 @@ Only available for holes without thread - Hole depth + Tapped (DIN76)