From 11cd684385d1aa23169dfc388b7c1bcd0393ac35 Mon Sep 17 00:00:00 2001 From: Richard Milewski Date: Wed, 16 Oct 2024 17:30:46 -0700 Subject: [PATCH 1/3] Update masks2d.scad Removed default "remove" tags. --- masks2d.scad | 50 ++++++++++++++++++-------------------------------- 1 file changed, 18 insertions(+), 32 deletions(-) diff --git a/masks2d.scad b/masks2d.scad index e3b0d9e..395cdbf 100644 --- a/masks2d.scad +++ b/masks2d.scad @@ -131,11 +131,9 @@ function _inset_corner(corner, mask_angle, inset, excess, flat_top) = module mask2d_roundover(r, inset=0, mask_angle=90, excess=0.01, flat_top, d, h, height, cut, quarter_round=false, joint, anchor=CENTER,spin=0) { path = mask2d_roundover(r=r, d=d, h=h, height=height, cut=cut, joint=joint, inset=inset, flat_top=flat_top, mask_angle=mask_angle, excess=excess, quarter_round=quarter_round); - default_tag("remove") { - attachable(anchor,spin, two_d=true, path=path) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path) { + polygon(path); + children(); } } @@ -322,11 +320,9 @@ function mask2d_teardrop(r, angle=45, inset=[0,0], mask_angle=90, excess=0.01, f module mask2d_teardrop(r, angle=45, mask_angle=90, excess=0.01, inset=0, flat_top=false, height, d, h, cut, joint, anchor=CENTER, spin=0) { path = mask2d_teardrop(r=r, d=d, h=h, height=height, flat_top=flat_top, cut=cut, joint=joint, angle=angle,inset=inset, mask_angle=mask_angle, excess=excess); - default_tag("remove") { - attachable(anchor,spin, two_d=true, path=path) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path) { + polygon(path); + children(); } } @@ -418,11 +414,9 @@ module mask2d_teardrop(r, angle=45, mask_angle=90, excess=0.01, inset=0, flat_to module mask2d_cove(r, inset=0, mask_angle=90, excess=0.01, flat_top, bulge, d, h, height, quarter_round=false, anchor=CENTER, spin=0) { path = mask2d_cove(r=r, d=d, h=h, height=height, bulge=bulge, flat_top=flat_top, quarter_round=quarter_round, inset=inset, mask_angle=mask_angle, excess=excess); - default_tag("remove") { - attachable(anchor,spin, two_d=true, path=path) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path) { + polygon(path); + children(); } } @@ -592,11 +586,9 @@ function mask2d_cove(r, inset=0, mask_angle=90, excess=0.01, flat_top, d, h, hei module mask2d_chamfer(edge, angle, inset=0, excess=0.01, mask_angle=90, flat_top=false, x, y, h, w, height, width, anchor=CENTER,spin=0) { path = mask2d_chamfer(x=x, y=y, edge=edge, angle=angle, height=height, h=h, excess=excess, w=w, inset=inset, mask_angle=mask_angle, flat_top=flat_top,width=width); - default_tag("remove") { - attachable(anchor,spin, two_d=true, path=path, extent=true) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path, extent=true) { + polygon(path); + children(); } } @@ -714,11 +706,9 @@ function mask2d_chamfer(edge, angle, inset=0, excess=0.01, mask_angle=90, flat_t // mask2d_rabbet(size=[5,10]); module mask2d_rabbet(size, mask_angle=90, excess=0.01, anchor=CTR, spin=0) { path = mask2d_rabbet(size=size, mask_angle=mask_angle, excess=excess); - default_tag("remove") { - attachable(anchor,spin, two_d=true, path=path, extent=false) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path, extent=false) { + polygon(path); + children(); } } @@ -804,11 +794,9 @@ function mask2d_rabbet(size, mask_angle=90, excess=0.01, anchor=CTR, spin=0) = // mask2d_dovetail(width=10,angle=30); module mask2d_dovetail(edge, angle, shelf=0, inset=0, mask_angle=90, excess=0.01, flat_top=true, w,h,width,height, slope, anchor=CENTER, spin=0,x,y) { path = mask2d_dovetail(w=w,width=width,h=h,height=height, edge=edge, angle=angle, inset=inset, shelf=shelf, excess=excess, slope=slope, flat_top=flat_top, mask_angle=mask_angle,x=x,y=y); - default_tag("remove") { - attachable(anchor,spin, two_d=true, path=path) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path) { + polygon(path); + children(); } } @@ -916,12 +904,10 @@ function mask2d_dovetail(edge, angle, slope, shelf=0, inset=0, mask_angle=90, ex // ]); module mask2d_ogee(pattern, excess=0.01, anchor=CENTER,spin=0) { path = mask2d_ogee(pattern, excess=excess); - default_tag("remove") { attachable(anchor,spin, two_d=true, path=path) { polygon(path); children(); } - } } function mask2d_ogee(pattern, excess=0.01, anchor=CENTER, spin=0) = From ddf5344498402ce62ca0de7c1a9c914e6845f342 Mon Sep 17 00:00:00 2001 From: Richard Milewski Date: Wed, 16 Oct 2024 17:34:10 -0700 Subject: [PATCH 2/3] Update masks2d.scad Fix indents in mask2d_ogee() --- masks2d.scad | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/masks2d.scad b/masks2d.scad index 395cdbf..5622f28 100644 --- a/masks2d.scad +++ b/masks2d.scad @@ -904,10 +904,10 @@ function mask2d_dovetail(edge, angle, slope, shelf=0, inset=0, mask_angle=90, ex // ]); module mask2d_ogee(pattern, excess=0.01, anchor=CENTER,spin=0) { path = mask2d_ogee(pattern, excess=excess); - attachable(anchor,spin, two_d=true, path=path) { - polygon(path); - children(); - } + attachable(anchor,spin, two_d=true, path=path) { + polygon(path); + children(); + } } function mask2d_ogee(pattern, excess=0.01, anchor=CENTER, spin=0) = From 0c4b0b1990f48cf913a8aae4f487e7e3a7546b9f Mon Sep 17 00:00:00 2001 From: Richard Milewski Date: Wed, 16 Oct 2024 17:43:42 -0700 Subject: [PATCH 3/3] Update masks2d.scad Corrected documentation re removal of default tags. --- masks2d.scad | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/masks2d.scad b/masks2d.scad index 5622f28..85efe3a 100644 --- a/masks2d.scad +++ b/masks2d.scad @@ -67,8 +67,6 @@ function _inset_corner(corner, mask_angle, inset, excess, flat_top) = // quarter_round = If true, make a roundover independent of the mask_angle, defined based on a quarter circle of the specified size. Creates mask with angle-independent height. Default: false. // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. // // Example(2D): 2D Roundover Mask by Radius // mask2d_roundover(r=10); @@ -233,8 +231,6 @@ function mask2d_roundover(r, inset=0, mask_angle=90, excess=0.01, flat_top, quar // flat_top = If true, the top inset of the mask will be horizontal instead of angled by the mask_angle. Default: true. // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. // Example(2D): 2D Teardrop Mask // mask2d_teardrop(r=10,$fn=64); // Example(2D): 2D Teardrop Mask for acute angle @@ -363,8 +359,6 @@ module mask2d_teardrop(r, angle=45, mask_angle=90, excess=0.01, inset=0, flat_to // flat_top = If true, the top inset of the mask will be horizontal instead of angled by the mask_angle. In the case of obtuse angles force the mask to have a flat section at its left side instead of a circular arc. Default: true if quarter_round is set, false otherwise. // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. // Example(2D): 2D Cove Mask by Radius // mask2d_cove(r=10); // Example(2D): 2D Inset Cove Mask (not much different than a regular cove of larger radius) @@ -518,8 +512,6 @@ function mask2d_cove(r, inset=0, mask_angle=90, excess=0.01, flat_top, d, h, hei // flat_top = If true, the top inset of the mask will be horizontal instead of angled by the mask_angle. Default: true. // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. // Example(2D): 2D Chamfer Mask, at 45 deg by default // mask2d_chamfer(x=10); // Example(2D): 2D Chamfer Mask, at 30 deg (measured down from vertical) @@ -681,8 +673,6 @@ function mask2d_chamfer(edge, angle, inset=0, excess=0.01, mask_angle=90, flat_t // --- // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. // Example(2D): 2D Rabbet Mask // mask2d_rabbet(size=10); // Example(2D): 2D Asymmetrical Rabbet Mask @@ -763,8 +753,6 @@ function mask2d_rabbet(size, mask_angle=90, excess=0.01, anchor=CTR, spin=0) = // flat_top = If true, the top inset of the mask will be horizontal instead of angled by the mask_angle. Default: true. // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. // Example(2D): 2D Dovetail Mask // mask2d_dovetail(width=10,angle=14); // Example(2D): 2D Dovetail Mask by height and slope. A slope of 1/6 is a common choice. @@ -872,9 +860,6 @@ function mask2d_dovetail(edge, angle, slope, shelf=0, inset=0, mask_angle=90, ex // anchor = Translate so anchor point is at origin (0,0,0). See [anchor](attachments.scad#subsection-anchor). Default: `CENTER` // spin = Rotate this many degrees around the Z axis after anchor. See [spin](attachments.scad#subsection-spin). Default: `0` // -// Side Effects: -// Tags the children with "remove" (and hence sets `$tag`) if no tag is already set. -// // Example(2D): 2D Ogee Mask // mask2d_ogee([ // "xstep",1, "ystep",1, // Starting shoulder.