Compare commits

..

No commits in common. "2a3f3bb568e3ec46738ccd5e8e86b8a35a875da3" and "d49fdc894867a3ae4a673a9c8689b82beccaf042" have entirely different histories.

View File

@ -1,4 +1,4 @@
import { ANGLE_TYPE, canvasState, currentAngleTypeSelector, globalPitchState, pitchTextSelector } from '@/store/canvasAtom'
import { ANGLE_TYPE, canvasState, currentAngleTypeSelector, pitchTextSelector } from '@/store/canvasAtom'
import { useRecoilValue } from 'recoil'
import { fabric } from 'fabric'
import { calculateIntersection, findAndRemoveClosestPoint, getDegreeByChon, getDegreeInOrientation, isPointOnLine } from '@/util/canvas-util'
@ -17,7 +17,6 @@ export const usePolygon = () => {
const lengthTextFontOptions = useRecoilValue(fontSelector('lengthText'))
const currentAngleType = useRecoilValue(currentAngleTypeSelector)
const pitchText = useRecoilValue(pitchTextSelector)
const globalPitch = useRecoilValue(globalPitchState)
const { getLengthByLine } = useLine()
@ -1338,7 +1337,7 @@ export const usePolygon = () => {
defense = 'south'
break
}
pitch = polygon.lines[index]?.attributes?.pitch ?? representLine?.attributes?.pitch ?? globalPitch
pitch = polygon.lines[index]?.attributes?.pitch ?? representLine?.attributes?.pitch ?? 0
const roof = new QPolygon(roofPoint, {
fontSize: polygon.fontSize,