Arch: rebar, make it possible to create a rebar without existence of a Structure

This commit is contained in:
Bernd Hahnebach
2019-04-26 09:09:32 +02:00
committed by Yorik van Havre
parent 3f2562669f
commit 377efe8d6a

View File

@@ -76,6 +76,12 @@ def makeRebar(baseobj=None,sketch=None,diameter=None,amount=1,offset=None,name="
if FreeCAD.GuiUp:
sketch.ViewObject.hide()
obj.Host = baseobj
elif sketch and not baseobj:
# a rebar could be based on a wire without the existance of a Structure
obj.Base = sketch
if FreeCAD.GuiUp:
sketch.ViewObject.hide()
obj.Host = None
if diameter:
obj.Diameter = diameter
else: