diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ba1fa8c..7657911 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -34,6 +34,7 @@ repos: - id: forbid-submodules - id: mixed-line-ending - id: trailing-whitespace + exclude: '(\.ui|\.svg)$' - repo: https://github.com/asottile/pyupgrade rev: v3.19.1 hooks: diff --git a/Information/CenterOfMass.FCMacro b/Information/CenterOfMass.FCMacro index 0b855ae..f7555af 100644 --- a/Information/CenterOfMass.FCMacro +++ b/Information/CenterOfMass.FCMacro @@ -1072,7 +1072,7 @@ class CenterofmassWidget(QtGui.QWidget): for s_ in ('CoMBBoxOfSel', 'CoMLCS', 'CoMTotal', 'CoMPlaneYZ', 'CoMPlaneXZ', 'CoMPlaneXY'): if self.doc.getObject(s_): self.doc.removeObject(s_) - + # Bounding box of valid selection BBoxSolid = self.doc.addObject('Part::Box', 'CoMBBoxOfSel') BBoxSolid.Placement.Base = self.boundBox.Center.sub(app.Vector(boundBoxL).multiply(0.5))