Pen issue


#1

I have a pen-related issue on my ASUS EP121 tablet running Windows 10. It appears since last 4.3.0 update. As soon as the pen enters detection area, a mouse down event is generated, but the pen didn’t actually touch the screen.

A first debug session took me to a call to sendMouseDown() (juce_gui_basics\mouse\juce_MouseInputSource.cpp:202) made while handling a WM_POINTERUPDATE in MouseInputSourceInternal::setButtons(). The call is made because buttonState holds the value 16. This value comes from a logic in HWNDComponentPeer::handleTouchInput() that might be incorrect… The modifiers from the message are 0, but line 2270 sets the leftButtonModifier flag:

    else
    {
        modsToSend = currentModifiers.withoutMouseButtons().withFlags (ModifierKeys::leftButtonModifier);
    }

Still with pen issues
#2

Are you on the latest tip of the develop branch? I made a number of commits last month improving pen input on Windows.

Ed


#3

I have downloaded the last package from the homepage today, I will try the latest version from GIT. Thanks!


#4

Ed, I got the dev branch from GitHub, and the “Mouse Down sent on WM_POINTERUPDATE” issue is fixed. Pen input is still not working though: menus open when clicking on them, but menu items don’t trigger their actions. Buttons are not working too. Everything is fine with touch.


#5

Hi!

You’d be doing me a great favour if you try long-press for right click as well - it is enabled by default on windows as far as I remember.

On my two touch-enabled computers running windows 10, the animated circle indicating a long press appears, but the right-click event never does as I imagine it should.


#6

Sorry for not answering for a lot of time but this very issue has prevented me from doing some serious work. No, long-press is not working, the animated circle doesn’t appear in Juce applications. Also, as soon as I pen-click in a text field, the whole text gets selected and I cannot change that.

EDIT: the behaviour when pen-clicking in a text field is actually the following: the first click selects the whole text; the subsequent clicks select a single word. No way to put the blinking cursor where I point the pen in a text field, in JUCE applications.

EDIT (2): every now and then, a click leaves the text field with just the blinking cursor and no text selected, but it seems unpredictable. I hope the devs can grab a tablet PC at last, and make some serious test on pen messages handling :slight_smile:


#7

Thanks for the reply, good to know!

I’ve had that issue too, and did report it: