Search code examples
windowsmousewacom

How to make stylus not control the mouse?


I want to separate the stylus position from the mouse position in a win32 application. I'm using the wintab sdk and I've seen articles about distinguishing between mousebuttondown/up events coming from the pen/eraser or mouse. But I haven't been able to find anything that lets you use the stylus as a second device. I want to respond to WT_PACKET events to determine the position of the pen for painting, and use the mouse cursor for other operations.


Solution

  • I figured it out.

    LOGCONTEXT lc;

    lc.lcOptions |= CXO_SYSTEM // this flag links it to the system cursor.

    return WTOpen(hWnd, &lc, TRUE;

    .....