Horizontal Scrolling Also Scrolls One Tick Vertically

Questions and answers about 3Dconnexion devices on Windows.

Moderator: Moderators

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

Horizontal Scrolling Also Scrolls One Tick Vertically

Post by LKM »

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: 3340
Joined: Wed Dec 20, 2006 2:25 pm
Location: USA
Contact:

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by jwick »

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: 6
Joined: Fri Dec 06, 2019 12:22 am

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by LKM »

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: 3340
Joined: Wed Dec 20, 2006 2:25 pm
Location: USA
Contact:

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by jwick »

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: 6
Joined: Fri Dec 06, 2019 12:22 am

Re: Horizontal Scrolling Also Scrolls One Tick Vertically

Post by LKM »

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