Stylus pen tilt direction incorrect on notebook touch screen

Hello there

I installed Manjaro (Cinnamon version) on a GPD Pocket 3

https://wiki.archlinux.org/title/GPD_Pocket_3

and set up most things more or less successfully. However, there is one strange thing happening with the pen tilt recognition (touch screen). My searches didn’t render a clue so far so maybe someone around here is able to lead me in the right direction. The Arch Wiki page (5.3) states that the Touchscreen and Digitizer support is a work in progress. I have not found a clue so far that the incorrect tilt functionality has even been registered somewhere so far.

xinput list
[...]
⎜   ↳ GXTP7380:00 27C6:0113 Stylus stylus     	id=11	[slave  pointer  (2)]
⎜   ↳ GXTP7380:00 27C6:0113 Stylus eraser     	id=14	[slave  pointer  (2)]
⎜   ↳ GXTP7380:00 27C6:0113 touch             	id=10	[slave  pointer  (2)]
[...]

So, the tilt recognition IS working, but the orientation is incorrect, as I tried to show in this picture:

https://drive.google.com/file/d/153ukTAEoNVfVfTh1G-Ki16Sgo5rKdWak/view?usp=sharing

The pointy end of the pencil should always be on the more opaque side of the stroke. Is there a way to adjust the pens tilt direction? I used two different brands of styli/styluses, both with the same result (in Krita). Both styli/styluses work as expected on a Microsoft Surface Go 2 running Mint/Cinnamon - also tested in Krita. In case more information is needed, let me know what and how to get it.

Thank you very much,
Michael

Hello,

According to that wiki, you use the "TransformationMatrix" "0 1 0 -1 0 1 0 0 1" and that is for when you should rotate the screen to the right (clockwise 90 degree). Otherwise if left (counterclockwise 90 degree) you have to use "TransformationMatrix" "0 -1 1 1 0 0 0 0 1"

Since Krita is Qt application but you run Cinnamon (gtk+) based DE, and the options/settings for stylus and tablet are more limited, there might be a “disconnect” there … hard to tell.
See if by adding

export QT_XCB_TABLET_LEGACY_COORDINATES=1

to your ~/.bash_profile and log out and back in makes a difference.

This is also a good resource to investigate some things Tablet PC - ArchWiki