diff --git a/src/Mod/Arch/ArchStairs.py b/src/Mod/Arch/ArchStairs.py index c74743c093..2f4c1c9c72 100644 --- a/src/Mod/Arch/ArchStairs.py +++ b/src/Mod/Arch/ArchStairs.py @@ -164,7 +164,9 @@ def makeRailing(stairs): stairs0OutlineWireLR = "OutlineWireRight" stairOutlineWireLR = "OutlineWireRight" if outlineLR or OutlineLRAll: - lrRail = ArchPipe.makePipe() + + lrRail = ArchPipe.makePipe(baseobj=None,diameter=0,length=0,placement=None,name="Rail") + if OutlineLRAll: lrRailWire = Draft.makeWire(OutlineLRAll) lrRail.Base = lrRailWire @@ -327,6 +329,7 @@ class _Stairs(ArchComponent.Component): if not "Align" in pl: obj.addProperty("App::PropertyEnumeration","Align","Stairs",QT_TRANSLATE_NOOP("App::Property","The alignment of these stairs on their baseline, if applicable")) obj.Align = ['Left','Right','Center'] + # TODO - To be combined into Width when PropertyLengthList is available if not "WidthOfLanding" in pl: obj.addProperty("App::PropertyFloatList","WidthOfLanding","Stairs",QT_TRANSLATE_NOOP("App::Property","The width of a Landing (2nd edge and after - 1st edge follow Width property")) @@ -601,13 +604,12 @@ class _Stairs(ArchComponent.Component): print (i) if i > 0: try: - if obj.WidthOfLanding[i-1] > 0: # Float has no .Value + if obj.WidthOfLanding[i-1] > 0: netWidthI = obj.WidthOfLanding[i-1] - offsetHLeft.Value - offsetHRight.Value #2*offsetH except: pass if netWidthI == 0: netWidthI = obj.Width.Value - offsetHLeft.Value - offsetHRight.Value #2*offsetH - vWidth.append(DraftVecUtils.scaleTo(vLength[i].cross(Vector(0,0,1)),netWidthI)) vBase.append(edges[i].Vertexes[0].Point)