I’m encountering an issue with my Huion tablet while using Krita on Linux.
The problem is that when I hover my pen over the tablet, the brush cursor on the canvas is offset by a few pixels to the right and bottom of the crosshair. This offset is consistent, roughly a 1:1 distance, and happens only during pen hovering.
If I go back to using the mouse, the brush outline re-centers to the crosshair and works as expected
Hello there!
I want to correct my previous description - the crosshair is actually the component that’s offset, not the brush outline. When I move the pen, the crosshair appears a few pixels to the left and top, while the brush itself remains precisely where you’d expect it. (Tested by moving back and forth between UI and canvas)
When switching to mouse, the crosshair aligns perfectly with the cursor. This offset happens only when using the pen.
It’s not a huge deal if I disable the crosshair, but it would be nice to have it accurate. The crosshair is very useful so I’d rather have it enabled
I’m not entirely certain, but it seems like maybe this could be a misalignment issue?
It might be related to the coordinates or pivot point of the crosshair image relative to the pen’s position. The offset appears to be approximately half the crosshair’s size on both the X and Y axes.
Upon further testing, I’m starting to wonder if there’s also a minor offset present when using the mouse, though it’s less noticeable
UPDATE: I’m not sure but seems like it could be related to high-dpi actually. I recently got a 4K monitor, and because of that I had to set scaling in KDE Plasma to 175%
I set it to 100% and didn’t notice the offset anymore but everything is too tiny to use so I’m back to 175% where the issue happens.
I tried enabling High-dpi support in Krita’s settings but it didn’t have any effect
You could try setting it to 150% or 200%, or -worst case- changing the resolution to 1440p or 1080p, but that will be blurry.
There are some environment variables to control QT scaling behavior, but I don’t remember them off hand… Maybe someone else knows if anything works for this.
Thanks for the help @YRH!
It’s indeed fractional scaling. The offset only happens at values like 175%, not at 100% or 200%.
Since it’s specifically the crosshair in Krita’s canvas that’s affected, and the pen input is otherwise accurate, it seems like something in Krita’s handling of fractional scaling and crosshair positioning.
At this point, I think it needs a dev’s eyes, as it might be a bug in how Krita recalculates coordinates with fractional scaling… But it’s hard to imagine that someone didn’t report this before, though I couldn’t find it…
Thanks for checking. Fractional support is tricky, especially on Linux, depending on your OS version it may be unsupported. Windows is typically more robust in this regard.
I suggest you report this on bugs.kde.org, that way the issue won’t be forgotten. I think 175% scaling is rather uncommon. You can check this thread for examples of bug reports.