diff --git a/src/Mod/Arch/ArchCommands.py b/src/Mod/Arch/ArchCommands.py index e3de4dede4..858010f9b0 100644 --- a/src/Mod/Arch/ArchCommands.py +++ b/src/Mod/Arch/ArchCommands.py @@ -744,7 +744,7 @@ def pruneIncluded(objectslist,strict=False): if obj.isDerivedFrom("Part::Feature"): if not (Draft.getType(obj) in ["Window","Clone","Pipe","Rebar"]): for parent in obj.InList: - if parent.isDerivedFrom("Part::Feature") and not (Draft.getType(parent) in ["Facebinder","Window","Roof","Clone","Site"]): + if parent.isDerivedFrom("Part::Feature") and not (Draft.getType(parent) in ["Space","Facebinder","Window","Roof","Clone","Site"]): if not parent.isDerivedFrom("Part::Part2DObject"): # don't consider 2D objects based on arch elements if hasattr(parent,"Host") and (parent.Host == obj): @@ -764,6 +764,8 @@ def pruneIncluded(objectslist,strict=False): toplevel = True if toplevel: newlist.append(obj) + else: + FreeCAD.Console.PrintLog("pruning "+obj.Label+"n") return newlist def getAllChildren(objectlist): diff --git a/src/Mod/Arch/ArchWall.py b/src/Mod/Arch/ArchWall.py index 046703fd62..ab8847c5aa 100644 --- a/src/Mod/Arch/ArchWall.py +++ b/src/Mod/Arch/ArchWall.py @@ -804,6 +804,7 @@ class _Wall(ArchComponent.Component): if hasattr(obj,"Material"): if obj.Material: if hasattr(obj.Material,"Materials"): + # multimaterials varwidth = 0 restwidth = width - sum(obj.Material.Thicknesses) if restwidth > 0: @@ -935,14 +936,15 @@ class _Wall(ArchComponent.Component): offset = 0 base = [] for l in layers: - l2 = length/2 or 0.5 - w1 = -totalwidth/2 + offset - w2 = w1 + l - v1 = Vector(-l2,w1,0) - v2 = Vector(l2,w1,0) - v3 = Vector(l2,w2,0) - v4 = Vector(-l2,w2,0) - base.append(Part.Face(Part.makePolygon([v1,v2,v3,v4,v1]))) + if l > 0: + l2 = length/2 or 0.5 + w1 = -totalwidth/2 + offset + w2 = w1 + l + v1 = Vector(-l2,w1,0) + v2 = Vector(l2,w1,0) + v3 = Vector(l2,w2,0) + v4 = Vector(-l2,w2,0) + base.append(Part.Face(Part.makePolygon([v1,v2,v3,v4,v1]))) offset += l else: l2 = length/2 or 0.5 diff --git a/src/Mod/Arch/ArchWindow.py b/src/Mod/Arch/ArchWindow.py index fdb32fd157..cebb76d588 100644 --- a/src/Mod/Arch/ArchWindow.py +++ b/src/Mod/Arch/ArchWindow.py @@ -1881,6 +1881,8 @@ class _ArchWindowTaskPanel: hinge = self.field6.property("text") n = self.field7.currentIndex() if (hinge.startswith("Edge")) and (n > 0): + # remove accelerator added by Qt + hinge = hinge.replace("&","") t += "," + hinge + ",Mode" + str(n) ar.append(t) diff --git a/src/Mod/Arch/importIFC.py b/src/Mod/Arch/importIFC.py index 1d85dd052f..4b0ddda662 100644 --- a/src/Mod/Arch/importIFC.py +++ b/src/Mod/Arch/importIFC.py @@ -1534,7 +1534,7 @@ def export(exportList,filename,colors=None): # clean objects list of unwanted types objectslist = [obj for obj in objectslist if obj not in annotations] objectslist = Arch.pruneIncluded(objectslist,strict=True) - objectslist = [obj for obj in objectslist if Draft.getType(obj) not in ["Material","MaterialContainer","WorkingPlaneProxy"]] + objectslist = [obj for obj in objectslist if Draft.getType(obj) not in ["Dimension","Material","MaterialContainer","WorkingPlaneProxy"]] if FULL_PARAMETRIC: objectslist = Arch.getAllChildren(objectslist) products = {} # { Name: IfcEntity, ... } @@ -2146,7 +2146,7 @@ def export(exportList,filename,colors=None): treated.append(c.Name) if subs: ifcfile.createIfcRelAggregates( - ifcopenshell.new(), + ifcopenshell.guid.new(), history, 'Assembly', '', @@ -2170,7 +2170,7 @@ def export(exportList,filename,colors=None): f = products[floor.Name] if children: ifcfile.createIfcRelContainedInSpatialStructure( - ifcopenshell.new(), + ifcopenshell.guid.new(), history, 'StoreyLink', '', diff --git a/src/Mod/Draft/DraftGui.py b/src/Mod/Draft/DraftGui.py index a990b23334..3144d660de 100644 --- a/src/Mod/Draft/DraftGui.py +++ b/src/Mod/Draft/DraftGui.py @@ -262,6 +262,7 @@ def displayExternal(internValue,decimals=None,dim='Length',showUnit=True,unit=No uom = "??" if not showUnit: uom = "" + decimals = abs(decimals) # prevent negative values fmt = "{0:."+ str(decimals) + "f} "+ uom displayExt = fmt.format(float(internValue) / float(conversion)) displayExt = displayExt.replace(".",QtCore.QLocale().decimalPoint())