모임지붕 selectable 수정
This commit is contained in:
parent
a7ffc17eb9
commit
6458b50894
@ -4480,7 +4480,7 @@ export function useMode() {
|
|||||||
stroke: 'red',
|
stroke: 'red',
|
||||||
strokeDashArray: [5, 5],
|
strokeDashArray: [5, 5],
|
||||||
strokeWidth: 1,
|
strokeWidth: 1,
|
||||||
selectable: true,
|
selectable: false,
|
||||||
fontSize: fontSize,
|
fontSize: fontSize,
|
||||||
name: 'trestle',
|
name: 'trestle',
|
||||||
lockMovementX: true, // X 축 이동 잠금
|
lockMovementX: true, // X 축 이동 잠금
|
||||||
@ -4504,9 +4504,10 @@ export function useMode() {
|
|||||||
const notSelectedTrestlePolygons = canvas?.getObjects().filter((obj) => obj.name === 'trestle' && !obj.selected)
|
const notSelectedTrestlePolygons = canvas?.getObjects().filter((obj) => obj.name === 'trestle' && !obj.selected)
|
||||||
if (trestlePolygons.length === 0) {
|
if (trestlePolygons.length === 0) {
|
||||||
alert('가대가 없습니다.')
|
alert('가대가 없습니다.')
|
||||||
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if (notSelectedTrestlePolygons.length > 0) {
|
if (drewRoofCells.length > 0) {
|
||||||
alert('기존 셀은 제거됩니다.')
|
alert('기존 셀은 제거됩니다.')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4531,7 +4532,10 @@ export function useMode() {
|
|||||||
drawRoofCells = trestle.fillCell({ width: 100, height: 50, padding: 0 })
|
drawRoofCells = trestle.fillCell({ width: 100, height: 50, padding: 0 })
|
||||||
trestle.direction = 'east'
|
trestle.direction = 'east'
|
||||||
}
|
}
|
||||||
|
drawCellsArray.push(drawRoofCells)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
setDrewRoofCells(drawCellsArray)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 외적을 계산하는 함수
|
// 외적을 계산하는 함수
|
||||||
|
|||||||
@ -1134,6 +1134,7 @@ export const splitPolygonWithLines = (polygon) => {
|
|||||||
fill: 'transparent',
|
fill: 'transparent',
|
||||||
strokeWidth: 3,
|
strokeWidth: 3,
|
||||||
name: 'roof',
|
name: 'roof',
|
||||||
|
selectable: false,
|
||||||
})
|
})
|
||||||
|
|
||||||
polygon.canvas.add(roof)
|
polygon.canvas.add(roof)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user