보조선 actualSize 0으로 수정

This commit is contained in:
hyojun.choi 2024-11-07 17:05:29 +09:00
parent a1527bc4af
commit c0396c9d6f
2 changed files with 3 additions and 2 deletions

View File

@ -138,7 +138,8 @@ export const QPolygon = fabric.util.createClass(fabric.Polygon, {
})
this.on('removed', () => {
const children = getAllRelatedObjects(this.id, this.canvas)
// const children = getAllRelatedObjects(this.id, this.canvas)
const children = this.canvas.getObjects().filter((obj) => obj.parentId === this.id && obj.name === 'lengthText')
children.forEach((child) => {
this.canvas.remove(child)
})

View File

@ -815,7 +815,7 @@ export function useAuxiliaryDrawing(id) {
roofBase.lines.some((line) => isPointOnLine(line, { x: line.x2, y: line.y2 }))
if (inPolygon1 && inPolygon2) {
line.attributes = { ...line.attributes, roofId: roofBase.id }
line.attributes = { ...line.attributes, roofId: roofBase.id, actualSize: 0, planeSize: line.getLength() }
return true
}
})