通过拖动鼠标在 ZedGraph 图中选择点
我想通过用鼠标拖动正方形来选择曲线上的点。当然我可以自己构建这个,但我想知道是否可以更容易地完成?
I would like to select points on my curve by dragging a square with my mouse. Of course I can build this myself, but I was wondering if it can be done easier?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
不幸的是没有。你必须自己做。 ZG 不提供任何更复杂的交互工具。
您可能需要订阅“鼠标按下”和“鼠标向上"事件,执行对找到的点进行反向变换,然后找到范围内的所有点(即通过在 曲线的点集合)。
请记住,您描述的操作默认是连接宽度缩放,您必须禁用它。
Unfortunately not. You would have to do it by yourself. ZG doesn't provide any more sophisticated tools for interaction.
You would probably need to subscribe for "mouse down" and "mouse up" events, perform the reverse transform of found points and then find all points in range (i.e. by searching inside the Points collection of your curve(s)).
Just remember, that the action you described is by default connected width zooming and you would have to disable it.