Horizontal Scrolling Also Scrolls One Tick Vertically

Questions and answers about 3Dconnexion devices on Windows.

Moderator: Moderators

Post Reply
LKM
Posts: 3
Joined: Fri Dec 06, 2019 12:22 am

Horizontal Scrolling Also Scrolls One Tick Vertically

Post by LKM » Fri Dec 06, 2019 12:36 am

I'm trying to get my SpaceMouse to scroll horizontally in Affinity Photo. This can be done by pressing Ctrl while scrolling using the mouse wheel. So I put the following code into my Photo.xml:
<Axis>
<Enabled>true</Enabled>
<Input>
<ActionID>HIDMultiAxis_Rz</ActionID>
<Min>-512</Min>
<Max>511</Max>
</Input>
<Output>
<Modifiers>
<Modifier>Control</Modifier>
</Modifiers>
<ActionID>HIDMouse_Wheel</ActionID>
</Output>
</Axis>
This does work, except for one detail: the Ctrl key seems to be only pressed after the first mouse wheel event is already sent, which means that every time I try to scroll horizontally, Affinity Photo first scrolls one tick up or down vertically. Is there any way to force the driver to push the modifier before starting to send the mouse event?

Also, as a follow-up question, I tried to switch to sending Ctr-+ or Ctrl-— isntead, but could not figure out how. I tried various permutations of the code below, but nothing worked. Is there any documentation for this XML format that I could read to get a better understanding of what options are available, and how they work?
<Axis>
<Enabled>true</Enabled>
<Input>
<ActionID>HIDMultiAxis_Rz</ActionID>
<Min>0</Min>
<Max>511</Max>
</Input>
<Output>
<ActionID>KB_Keystroke</ActionID>
<RepeatStyle>PressAndHold</RepeatStyle>
<KeyStroke>
<Key>107</Key>
</KeyStroke>
<Modifiers>
<Modifier>Control</Modifier>
</Modifiers>
</Output>
</Axis>

jwick
Moderator
Moderator
Posts: 2585
Joined: Wed Dec 20, 2006 2:25 pm
Location: USA
Contact:

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by jwick » Fri Dec 06, 2019 1:28 am

The log file lists exactly what it is sending.
That sounds like a bug if it is out of order. I'll have a look.

The latter XML is not valid. It's not as flexible as you might hope. I like your suggested usage though. I'll keep it in mind.

There are MotionMacros that allow you to string together a series of motion events. But that's not what you are trying to do here.

Sorry. There is currently no external doc on the XML format. The best doc is to ask me for help. I never intended people to edit the XML. There was a GUI to do this.

LKM
Posts: 3
Joined: Fri Dec 06, 2019 12:22 am

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by LKM » Fri Dec 06, 2019 4:31 am

Thanks for the response! The hint with the log actually solved my problem. Turns out that I was also slightly tilting the mouse, which caused a scroll event, so the problem was actually me, not the mouse itself.

Is the GUI to edit the XML available somewhere?

jwick
Moderator
Moderator
Posts: 2585
Joined: Wed Dec 20, 2006 2:25 pm
Location: USA
Contact:

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by jwick » Fri Dec 06, 2019 5:36 am

You might want to add a deadzone on the axes (all or just one) if you are accidentally activating it. The devices are sometimes too sensitive.

LKM
Posts: 3
Joined: Fri Dec 06, 2019 12:22 am

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by LKM » Fri Dec 06, 2019 8:13 am

Awesome, with the deadzone it works perfectly! Thank you so much!

Post Reply