Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

editor编辑框操作折线旋转中心点在屏幕外面或者距离旋转中心偏差较大 #307

Open
hzc12345678 opened this issue Dec 26, 2024 · 3 comments

Comments

@hzc12345678
Copy link

editor编辑框操作折线旋转中心点在屏幕外面或者距离旋转中心偏差较大
LinePen.value
LinePen.value = Line.one({
strokeWidth: pxToPx(10),
points: [],
stroke: '#FF4A2C',
...currentStyle.value,
})
leaferApp.tree.add(LinePen.value)
leaferApp.editor.select(LinePen.value)
leaferApp.on(PointerEvent.CLICK, LinePenCLICK)
leaferApp.on(PointerEvent.DOUBLE_CLICK, LinePenDOUBLE_CLIC)

function LinePenCLICK(e) {
LinePenArrs.value.push(e.x, e.y)
LinePen.value.set({ points: [...LinePenArrs.value] })
if (!LinerPenMoveShow.value) {
LinerPenMoveShow.value = true
leaferApp.on(PointerEvent.MOVE, LinerPenMove)
}
}
function LinePenDOUBLE_CLIC(e) {
LinePen.value.editable = true
eliminateLinePen()
}
点击动态添加折线路径 双击完成绘制 并打开editable ,发现折线使用编辑框旋转时旋转中心未在图形中心 而是外屏幕外面

@leaferjs
Copy link
Owner

是不是版本比较老?

@hzc12345678
Copy link
Author

是不是版本比较老?

昨天刚下载的最新版本

@hzc12345678
Copy link
Author

是不是版本比较老?

Snipaste_2024-12-27_09-51-35
Snipaste_2024-12-27_09-51-50

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants