Add hexnut heights

This commit is contained in:
Florian Festi 2016-03-23 09:12:14 +01:00
parent 87250c4142
commit 8be860d2d3
1 changed files with 21 additions and 21 deletions

View File

@ -460,26 +460,26 @@ class FingerHoles:
class NutHole:
sizes = {
"M1.6" : 3.2,
"M2" : 4,
"M2.5" : 5,
"M3" : 5.5,
"M4" : 7,
"M5" : 8,
"M6" : 10,
"M8" : 13,
"M10" : 16,
"M12" : 18,
"M14" : 21,
"M16" : 24,
"M20" : 30,
"M24" : 36,
"M30" : 46,
"M36" : 55,
"M42" : 65,
"M48" : 75,
"M56" : 85,
"M64" : 95,
"M1.6" : (3.2, 1.3),
"M2" : (4, 1.6),
"M2.5" : (5, 2.0),
"M3" : (5.5, 2.4),
"M4" : (7, 3.2),
"M5" : (8, 4.7),
"M6" : (10, 5.2),
"M8" : (13, 6.8),
"M10" : (16, 8.4),
"M12" : (18, 10.8),
"M14" : (21, 12.8),
"M16" : (24, 14.8),
"M20" : (30, 18.0),
"M24" : (36, 21.5),
"M30" : (46, 25.6),
"M36" : (55, 31),
"M42" : (65, 34),
"M48" : (75, 38),
"M56" : (85, 45),
"M64" : (95, 51),
}
def __init__(self, boxes, settings):
@ -489,7 +489,7 @@ class NutHole:
@restore
def __call__(self, size, x=0, y=0, angle=0):
size = self.sizes.get(size, size)
size = self.sizes.get(size, (size,))[0]
side = size / 3**0.5
self.boxes.moveTo(x, y, angle)
self.boxes.moveTo(-0.5*side, 0.5*size, angle)