Skip to content

Commit

Permalink
Merge pull request #55 from martinmcu/StripedGridParams
Browse files Browse the repository at this point in the history
Parameterize label striped grid for Issue #50
  • Loading branch information
dppdppd committed Mar 5, 2023
2 parents b70a860 + c23eae5 commit 7773320
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,12 @@ value is expected to be a number, and determines the thickness of the lid label
#### `LID_LABELS_BORDER_THICKNESS`
value is expected to be a number, and determines the thickness of the lid label border. Default is 0.3 mm

#### `LID_STRIPE_WIDTH`
value is expected to be a number, and determines the thickness of the lines in the striped grid behind the label. Default is 0.5 mm

#### `LID_STRIPE_SPACE`
value is expected to be a number, and determines the spacing of the lines in the striped grid behind the label. Default is 1.0 mm

#### `LID_HEIGHT`
value is expected to be a number, and determines whether how deep the lid is. Default is 1mm for inset lids, and 2mm for cap lids.

Expand Down
6 changes: 5 additions & 1 deletion boardgame_insert_toolkit_lib.2.scad
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@ LID_LABELS_INVERT_B = "lid_label_inverted";
LID_SOLID_LABELS_DEPTH = "lid_label_depth";
LID_LABELS_BG_THICKNESS = "lid_label_bg_thickness";
LID_LABELS_BORDER_THICKNESS = "lid_label_border_thickness";
LID_STRIPE_WIDTH = "lid_stripe_width";
LID_STRIPE_SPACE = "lid_stripe_space";
LID_INSET_B = "lid_inset";
LID_TABS_4B = "lid_tabs";

Expand Down Expand Up @@ -578,6 +580,8 @@ module MakeBox( box )

m_lid_label_bg_thickness = __value( m_lid, LID_LABELS_BG_THICKNESS, default = 2.0 );
m_lid_label_border_thickness = __value( m_lid, LID_LABELS_BORDER_THICKNESS, default = 0.3 );
m_lid_stripe_width = __value( m_lid, LID_STRIPE_WIDTH, default = 0.5 );
m_lid_stripe_space = __value( m_lid, LID_STRIPE_SPACE, default = 1 );

m_lid_pattern_n1 = __value( m_lid, LID_PATTERN_N1, default = 6 );
m_lid_pattern_n2 = __value( m_lid, LID_PATTERN_N2, default = 6 );
Expand Down Expand Up @@ -1766,7 +1770,7 @@ module MakeBox( box )

translate( [x/2-x2/2, y/2-y2/2, 0])
RotateAboutPoint( theta, [0,0,1], [x2/2,y2/2,0] )
MakeStripedGrid( x = x2, y = y2, w = 0.5, dx = 1, dy = 0, depth_ratio = 0.5, thickness = thickness );
MakeStripedGrid( x = x2, y = y2, w = m_lid_stripe_width, dx = m_lid_stripe_space, dy = 0, depth_ratio = 0.5, thickness = thickness );

MakeAllLidLabelFrames( offset = m_lid_label_bg_thickness, thickness = thickness );
}
Expand Down

0 comments on commit 7773320

Please sign in to comment.