InkCanvas 笔尖时间戳
在 WinForms 的 Microsoft.Ink 世界中,使用 InkCollector 对象,用户可以通过 这种方法。 WPF 世界依赖于 InkCanvas 对象,虽然它有很多属性,但我似乎找不到笔画中收集的 StylusPoints 的刻度或时间戳。在 WPF InkCanvas 中是否有等效的方法来执行此操作?
看起来我可以截取笔画这样,但 StylusPoint 是一个密封结构,因此我不能仅继承/添加新属性。
in the Microsoft.Ink world for WinForms, using an InkCollector object, a user could get the timestamp of a point in a stroke via this approach. The WPF world relies instead on the InkCanvas object, and while it has many properties, I can't seem to find a Tick or Timestamp for StylusPoints collected in the strokes. Is there an equivilant way to do this in the WPF InkCanvas?
it looks like I can intercept the strokes like this, but the StylusPoint is a sealed struct, so I can't just inherit/add a new property.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
从您显示的链接中,函数的参数是 RawStylusInput - http://msdn.microsoft.com/en-us/library/system.windows.input.stylusplugins.rawstylusinput.aspx - 具有 Timestamp 属性。
因此,您似乎无法访问每个点的时间戳,而是每个事件的时间戳。我怀疑这就是 WinForms 提供的所有解决方案。
From the link you showed, the parameter to the functions is RawStylusInput - http://msdn.microsoft.com/en-us/library/system.windows.input.stylusplugins.rawstylusinput.aspx - which has a Timestamp property.
So, it seems you don't have access to a timestamp per point, but for each event. I suspect that's all the resolution available from WinForms anyway.