PartDesign: Fix placement issue with thickness tool when the feature was empty.

This commit is contained in:
Paddle
2023-03-24 15:16:09 +01:00
parent d896d00d48
commit de6038ff9b

View File

@@ -76,10 +76,16 @@ App::DocumentObjectExecReturn *Thickness::execute()
//If no element is selected, then we use a copy of previous feature.
if (subStrings.empty()) {
//We must set the placement of the feature in case it's empty.
this->positionByBaseFeature();
this->Shape.setValue(TopShape);
return App::DocumentObject::StdReturn;
}
/* If the feature was empty at some point, then Placement was set by positionByBaseFeature.
* However makeThickSolid apparantly requires the placement to be empty, so we have to clear it*/
this->Placement.setValue(Base::Placement());
TopTools_ListOfShape closingFaces;
for (std::vector<std::string>::const_iterator it = subStrings.begin(); it != subStrings.end(); ++it) {