fixed closed paths
This commit is contained in:
parent
3a51ce9843
commit
05a7355a7f
1 changed files with 3 additions and 2 deletions
5
paths.go
5
paths.go
|
@ -281,8 +281,9 @@ func (cv *Canvas) ClosePath() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cv.LineTo(cv.linePath[closeIdx].pos[0], cv.linePath[closeIdx].pos[1])
|
cv.LineTo(cv.linePath[closeIdx].pos[0], cv.linePath[closeIdx].pos[1])
|
||||||
cv.linePath[len(cv.linePath)-1].next = cv.linePath[closeIdx].tf
|
cv.linePath[len(cv.linePath)-1].next = cv.linePath[closeIdx].next
|
||||||
cv.polyPath[len(cv.polyPath)-1].next = cv.polyPath[closeIdx].tf
|
cv.linePath[len(cv.linePath)-1].flags |= pathAttach
|
||||||
|
cv.polyPath[len(cv.polyPath)-1].next = cv.polyPath[closeIdx].next
|
||||||
}
|
}
|
||||||
|
|
||||||
// Stroke uses the current StrokeStyle to draw the path
|
// Stroke uses the current StrokeStyle to draw the path
|
||||||
|
|
Loading…
Reference in a new issue