View unanswered posts | View active topics It is currently 2020-08-04 10:10



Reply to topic  [ 2 posts ] 
 画布标尺线如何绘制? 
Author Message
新手上路

Joined: 2020-06-18 7:19
Posts: 23
Post 画布标尺线如何绘制?
我用的5.9.3版本的例子中有一个CloudEditor实例有标尺线,请问如何绘制?在代码中没找到相应的方法!我想绘制画布的标尺线,并且在移动节点后能让节点的位置微调至标尺绘制的交点上,求方法!


2020-07-08 14:30
Profile
TWaver开发组
User avatar

Joined: 2019-04-23 11:02
Posts: 88
Post Re: 画布标尺线如何绘制?
GridNetwork.js中 paintBottom方法就是绘制那个网格线的。
您说的微调到线上 这个功能可不好实现,一般都是对齐其他网元,思路是在鼠标down的时候或者拖动的时候用鼠标下的网元rect对比其他网元的rect,
鼠标up的时候根据设定参考范围做一个吸附之类的。


2020-07-08 16:50
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 2 posts ] 

Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron