Bug 491143 - [Graphics Tablet]: Tooltips appear at the mouse cursor location instead of the stylus location
Summary: [Graphics Tablet]: Tooltips appear at the mouse cursor location instead of th...
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 6.1.3
Platform: Other Linux
: NOR minor
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-08-01 21:25 UTC by duha.bugs
Modified: 2024-08-20 22:59 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.1.5
Sentry Crash Report:


Attachments
tooltip_wrong_place (1.32 MB, image/png)
2024-08-01 21:25 UTC, duha.bugs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description duha.bugs 2024-08-01 21:25:28 UTC
Created attachment 172196 [details]
tooltip_wrong_place

SUMMARY
When using a (tablet) stylus, tooltips appear at a random location

STEPS TO REPRODUCE
1. Open an app
2.  Hover with the stylus above something that creates a tooltip (like window decoration)

Can reproduce on both Master and 6.1.3

ADDITIONAL INFORMATION
Note: On the screenshot the cursor appears near the tooltip. On my screen the cursor was actually hovering the close button.
Comment 1 fanzhuyifan 2024-08-01 21:53:29 UTC
I suspect the underlying reason is that the stylus cursor and the mouse cursor are different, and the tooltip is displayed at the mouse cursor.
Comment 2 duha.bugs 2024-08-01 22:07:13 UTC
(In reply to fanzhuyifan from comment #1)
> I suspect the underlying reason is that the stylus cursor and the mouse
> cursor are different, and the tooltip is displayed at the mouse cursor.

Yes you are correct. They appear in fact at the mouse cursor location.
Comment 3 fanzhuyifan 2024-08-01 22:08:25 UTC
(In reply to duha.bugs from comment #2)
> (In reply to fanzhuyifan from comment #1)
> > I suspect the underlying reason is that the stylus cursor and the mouse
> > cursor are different, and the tooltip is displayed at the mouse cursor.
> 
> Yes you are correct. They appear in fact at the mouse cursor location.

TBH I still don't understand why we need two separate cursors... That seems to be causing quite a few problems.
Comment 4 duha.bugs 2024-08-01 22:36:30 UTC
(In reply to fanzhuyifan from comment #3)
> TBH I still don't understand why we need two separate cursors... That seems
> to be causing quite a few problems.

As best as I can tell this an upstream decision. So I don't think this will change.
Comment 5 fanzhuyifan 2024-08-01 22:45:34 UTC
(In reply to duha.bugs from comment #4)
> (In reply to fanzhuyifan from comment #3)
> > TBH I still don't understand why we need two separate cursors... That seems
> > to be causing quite a few problems.
> 
> As best as I can tell this an upstream decision. So I don't think this will
> change.

I think on wayland this is actually implemented im kwin
Comment 6 David Redondo 2024-08-20 14:16:08 UTC
I can confirm it.

Difference for me the cursor crosshair appears where it should.  Is that just something on the screenshot?
Comment 7 David Redondo 2024-08-20 14:16:35 UTC
nvm just read your note.
Comment 8 Bug Janitor Service 2024-08-20 14:58:19 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/6286
Comment 9 David Redondo 2024-08-20 21:44:39 UTC
Git commit aa88904b538a67e0f8827d193b794b05c4b408fb by David Redondo.
Committed on 20/08/2024 at 20:54.
Pushed by vladz into branch 'master'.

decorations: Show tooltip at current cursor position

instead of at the mouse position. Fixes tooltips showing
up in wrong places when using tablets.
FIXED-IN: 6.1.5

M  +1    -1    src/decorations/decoratedclient.cpp

https://invent.kde.org/plasma/kwin/-/commit/aa88904b538a67e0f8827d193b794b05c4b408fb
Comment 10 Vlad Zahorodnii 2024-08-20 22:59:10 UTC
Git commit a6f5f16c88cef21f99dfebee2ba506f860aec279 by Vlad Zahorodnii.
Committed on 20/08/2024 at 21:45.
Pushed by vladz into branch 'Plasma/6.1'.

decorations: Show tooltip at current cursor position

instead of at the mouse position. Fixes tooltips showing
up in wrong places when using tablets.
FIXED-IN: 6.1.5


(cherry picked from commit aa88904b538a67e0f8827d193b794b05c4b408fb)

Co-authored-by: David Redondo <kde@david-redondo.de>

M  +1    -1    src/decorations/decoratedclient.cpp

https://invent.kde.org/plasma/kwin/-/commit/a6f5f16c88cef21f99dfebee2ba506f860aec279