如何在WPF中手动向InkCanvas提交事件?
我如何能够手动提交事件以供 InkCanvas 接收?
我需要做的是将 InkCanvas 的模式设置为墨迹模式,然后将虚拟事件发送到 InkCanvas,以便我获得就像用户使用真实鼠标一样的绘图行为。
谢谢
How would I be able to submit events manually to be received by InkCanvas ?
What I need to do, is to set the mode of InkCanvas to ink mode, and then, send virtual events to InkCanvas so that I get a drawing behavior as if user used the real mouse.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
以下代码片段显示了在 InkCanvas 中绘制形状的示例:
其中 canvas 的类型为 InkCanvas。上面在画布中生成了一个三角形。
“是的,如果答案对您有帮助,您可以接受。”
The following code snippet shows an example of drawing a shape in InkCanvas:
Where canvas is of type InkCanvas. The above generates a triangle in the canvas.
"And yes, you may accept the answer if it helps you."
像这样的东西吗?
Something like this?