From 4d41b2ddb1a70106f090136590171674a1b81bd6 Mon Sep 17 00:00:00 2001 From: Florian Festi Date: Sun, 1 Jan 2023 23:58:22 +0100 Subject: [PATCH] FingerHolesEdge: Add bottom_lip parameter to support boxes that stack on top of each other like milk crates --- boxes/edges.py | 13 +++++++++++++ documentation/src/usermanual.rst | 3 +++ 2 files changed, 16 insertions(+) diff --git a/boxes/edges.py b/boxes/edges.py index 221b99e..e61a35f 100644 --- a/boxes/edges.py +++ b/boxes/edges.py @@ -845,6 +845,7 @@ Values: * edge_width : 1.0 : space below holes of FingerHoleEdge (multiples of thickness) * play : 0.0 : extra space to allow finger move in and out (multiples of thickness) * extra_length : 0.0 : extra material to grind away burn marks (multiples of thickness) + * bottom_lip : 0.0 : height of the bottom lips sticking out (multiples of thickness) FingerHoleEdge only! """ absolute_params = { @@ -860,6 +861,7 @@ Values: "edge_width": 1.0, "play" : 0.0, "extra_length" : 0.0, + "bottom_lip" : 0.0, } def checkValues(self): @@ -1090,12 +1092,23 @@ class FingerHoleEdge(BaseEdge): self.fingerHoles( 0, self.burn + dist + self.settings.thickness / 2, length, 0, bedBolts=bedBolts, bedBoltSettings=bedBoltSettings) + if self.settings.bottom_lip: + h = self.settings.bottom_lip + \ + self.fingerHoles.settings.edge_width + sp = self.boxes.spacing + self.moveTo(-sp/2, -h - sp) + self.rectangularWall(length - 1.05 * self.boxes.thickness, h) self.edge(length, tabs=2) def startwidth(self): """ """ return self.fingerHoles.settings.edge_width + self.settings.thickness + def margin(self): + if self.settings.bottom_lip: + return self.settings.bottom_lip + self.fingerHoles.settings.edge_width + self.boxes.spacing + else: + return 0 class CrossingFingerHoleEdge(Edge): """Edge with holes for finger joints 90° above""" diff --git a/documentation/src/usermanual.rst b/documentation/src/usermanual.rst index dd1bc1c..aeb92a6 100644 --- a/documentation/src/usermanual.rst +++ b/documentation/src/usermanual.rst @@ -207,6 +207,9 @@ Finger Joint Settings extra_length Make the outset part of the finger joint longer to allow grinding off burn marks. Note that this may not be great for non 90° joints where the corner is butted against the opposing cutout. + bottom_lip + Generate pieces to be glued on the inside of finger hole edges. This allows stacking boxes on top of each other. Note that finger hole edges that are used elsewhere may not have use of these pieces and you should probably just delete them before cutting. + Stackable Edge Settings .......................