How to get accurate Java Swing mouse events on a Microsoft pen device? -


has found solution timing of java swing mouse events on surface pro or other microsoft wacom pen platform?

the goal create responsive pen stroke input in draw type application, including @ start of stroke.

this problem occurs on surface pro running windows 8. observed on toshiba tabletpc running xp. on both devices, believe pen sensor wacom.

the problem timing of mousepressed , mousedragged events. simple program have mousepressed event initiate stroke, , subsequent mousedragged events add points it.

ostensibly, mouse , pen should behave in triggering these events.

but in fact observe timing different. mouse, mousedragged event occurs 8 milliseconds after mousepressed event. cool.

with pen, however, behavior weird. when pen touched down, mousepressed event gets triggered promptly. there's significant delay before first mousedragged event gets sent. wrecks start of pen strokes. calls system.currenttimemillis() returns deceitful answers. these calls mousepressed event , subsequent mousedragged event occur @ same time. cannot possible because event locations wildly different.

there must funny going on between o/s, wacom drivers, , java. has encountered this, or better yet, solution?


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -