Created
January 10, 2015 20:33
-
-
Save fsantini/b724853f027a95b34e08 to your computer and use it in GitHub Desktop.
FreeCAD macro for deleting a group object together with its children
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Part, FreeCAD, math, PartGui, FreeCADGui | |
from FreeCAD import Base, Console | |
def delWithChildren(obj): | |
doc = FreeCAD.ActiveDocument | |
for o in obj.OutList: | |
delWithChildren(o) | |
doc.removeObject(obj.Name) | |
sel = FreeCADGui.Selection.getSelection() # " sel " contains the items selected | |
for obj in sel: | |
delWithChildren(obj) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment