2
votes

I've created a WPF touchscreen application at work.

When I use a mouse, it behaves as you would expect. However, when using the touchscreen it doesn't behave as it should. It will regularly lag on a PreviewMouseDown touch event, and sometimes won't actually respond at all. Other times it works fine.

Does anybody know what could cause this behaviour, and what can I do to resolve it?

Many thanks

1
what version of wpf? there were a lot of touch improvements in wpf in .net 4.6.1 blogs.msdn.microsoft.com/wpf/2015/10/29/wpf-in-net-4-6-1John Gardner
I'm definitely having the same issue....net 4.6.1 doesn't help.jharr100

1 Answers

0
votes

In researching the issue for someone over at EE, I ran across this post. Essentially, the PreviewTouchDown event does not occur until a finger touches the screen and moves. The answering post author goes on to say

To cause the PreviewTouchDown event to occur as soon as a finger touches the screen, set the Stylus.IsPressAndHoldEnabled attached property to false for this element.

This solution was posted in early 2014 and hasn't been rebutted, so it should work.