🐛 Fixed hem allowance in Bruce, fixes #106
This commit is contained in:
parent
7aa500d960
commit
eee23f1592
2 changed files with 28 additions and 10 deletions
|
@ -31,18 +31,28 @@ export default function(part) {
|
||||||
)
|
)
|
||||||
|
|
||||||
// Path
|
// Path
|
||||||
paths.seam = new Path()
|
paths.saBase = new Path()
|
||||||
.move(points.topLeft)
|
.move(points.bottomRight)
|
||||||
.line(points.bottomLeft)
|
|
||||||
.line(points.bottomRight)
|
|
||||||
.line(points.tip)
|
.line(points.tip)
|
||||||
.curve(points.tipCpBottom, points.tipCpTop, points.topLeft)
|
.curve(points.tipCpBottom, points.tipCpTop, points.topLeft)
|
||||||
|
.line(points.bottomLeft)
|
||||||
|
paths.hemBase = new Path().move(points.bottomLeft).line(points.bottomRight)
|
||||||
|
paths.saBase.render = false
|
||||||
|
paths.hemBase.render = false
|
||||||
|
paths.seam = paths.saBase
|
||||||
|
.join(paths.hemBase)
|
||||||
.close()
|
.close()
|
||||||
.attr('class', 'fabric')
|
.attr('class', 'fabric')
|
||||||
|
|
||||||
// Complete pattern?
|
// Complete pattern?
|
||||||
if (complete) {
|
if (complete) {
|
||||||
if (sa) paths.sa = paths.seam.offset(sa).attr('class', 'fabric sa')
|
if (sa) {
|
||||||
|
paths.sa = paths.saBase
|
||||||
|
.offset(sa)
|
||||||
|
.join(paths.hemBase.offset(sa * 2))
|
||||||
|
.close()
|
||||||
|
.attr('class', 'fabric sa')
|
||||||
|
}
|
||||||
points.title = points.topLeft.shiftFractionTowards(points.bottomRight, 0.5)
|
points.title = points.topLeft.shiftFractionTowards(points.bottomRight, 0.5)
|
||||||
macro('title', {
|
macro('title', {
|
||||||
at: points.title.shift(-90, 15),
|
at: points.title.shift(-90, 15),
|
||||||
|
|
|
@ -44,12 +44,16 @@ export default function(part) {
|
||||||
points.topRight = points.topRight.shift(90, store.get('frontRise'))
|
points.topRight = points.topRight.shift(90, store.get('frontRise'))
|
||||||
|
|
||||||
// Path
|
// Path
|
||||||
paths.seam = new Path()
|
paths.saBase = new Path()
|
||||||
.move(points.topLeft)
|
.move(points.bottomLeft)
|
||||||
|
.line(points.topLeft)
|
||||||
.line(points.topRight)
|
.line(points.topRight)
|
||||||
.line(points.bottomRight)
|
.line(points.bottomRight)
|
||||||
.line(points.bottomLeft)
|
paths.hemBase = new Path().move(points.bottomRight).line(points.bottomLeft)
|
||||||
.line(points.topLeft)
|
paths.saBase.render = false
|
||||||
|
paths.hemBase.render = false
|
||||||
|
paths.seam = paths.saBase
|
||||||
|
.join(paths.hemBase)
|
||||||
.close()
|
.close()
|
||||||
.attr('class', 'fabric')
|
.attr('class', 'fabric')
|
||||||
|
|
||||||
|
@ -65,7 +69,11 @@ export default function(part) {
|
||||||
title: 'side'
|
title: 'side'
|
||||||
})
|
})
|
||||||
if (sa) {
|
if (sa) {
|
||||||
paths.sa = paths.seam.offset(sa * -1).attr('class', 'fabric sa')
|
paths.sa = paths.saBase
|
||||||
|
.offset(sa * -1)
|
||||||
|
.join(paths.hemBase.offset(sa * -2))
|
||||||
|
.close()
|
||||||
|
.attr('class', 'fabric sa')
|
||||||
}
|
}
|
||||||
macro('grainline', {
|
macro('grainline', {
|
||||||
from: new Point(points.bottomRight.x / 2, points.bottomRight.y),
|
from: new Point(points.bottomRight.x / 2, points.bottomRight.y),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue