Bug 153333 - Plasma Wayland: Invisible or wrong cursor when inserting geometric shapes etc.
Summary: Plasma Wayland: Invisible or wrong cursor when inserting geometric shapes etc.
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
Version:
(earliest affected)
7.5.0.3 release
Hardware: All Linux (All)
: medium normal
Assignee: Michael Weghorn
URL:
Whiteboard: target:7.6.0 target:7.5.2
Keywords:
: 155672 158079 (view as bug list)
Depends on:
Blocks: Wayland KDE
  Show dependency treegraph
 
Reported: 2023-02-02 21:07 UTC by Jan Rathmann
Modified: 2023-11-08 08:49 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Rathmann 2023-02-02 21:07:55 UTC
Description:
Original bug report:
https://bugs.kde.org/show_bug.cgi?id=465164

On KDE Plasma Wayland when running Libreoffice with kf5 backend, the mouse cursor in the main pane of the LO window is either wrong or becomes invisible when performing certain "drawing" operations, like inserting a rectangle or a text field.

On Plasma 5.25/5.26: Wrong cursor image (not the usual cross hair)
On Plasma 5.27 beta: Cursor invisible

Steps to Reproduce:
1. Boot into Plasma. Wayland session.
2. Run Libreoffice with kf5 support.
   (I discovered it while using LO Draw, but e.g. LO Writer is also affected)
3. Try to insert a rectangle or some other shape, or a text field.

Actual Results:
After clicking the button of the thing you want to insert, the cursor becomes invisible while being in the "main pane" of the LO window.

Expected Results:
The cursor stays visible and morphs into the usual cross hair icon to indicate one can now draw something.


Reproducible: Always


User Profile Reset: Yes

Additional Info:
I can reproduce this on VirtualBox and real HW.

It does not happen on X11, and when running LO on Wayland with the generic backend: SAL_USE_VCLPLUGIN=gen libreoffice

I can reproduce it on: (with pristine user accounts)
* Kubuntu 22.10 + Plasma 5.27 beta PPA, with LO 7.4
* Neon unstable (Plasma 5.27 beta), with LO 7.3 and 7.5
(invisible cursor)
* Kubuntu 22.10 live image (Plasma 5.25), with LO 7.4 
* Neon user live image (Plasma 5.26), with LO 7.3
(wrong cursor)
Comment 1 Stéphane Guillou (stragu) 2023-02-17 23:15:01 UTC
Reproduced in:

Version: 7.5.0.3 (X86_64) / LibreOffice Community
Build ID: c21113d003cd3efa8c53188764377a8272d9d6de
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: kf5 (cairo+wayland)
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded
Comment 2 Michael Weghorn 2023-02-20 13:18:38 UTC
This is a Qt bug:
https://bugreports.qt.io/browse/QTBUG-95434

I've suggested a change that makes this work for me with the qt6 VCL plugin:
https://codereview.qt-project.org/c/qt/qtwayland/+/461361
Comment 3 Stéphane Guillou (stragu) 2023-02-20 16:03:51 UTC
Excellent, thank you Michael for following up and submitting a patch upstream!
Comment 4 Michael Weghorn 2023-02-21 07:39:44 UTC
(In reply to Michael Weghorn from comment #2)
> This is a Qt bug:
> https://bugreports.qt.io/browse/QTBUG-95434
> 
> I've suggested a change that makes this work for me with the qt6 VCL plugin:
> https://codereview.qt-project.org/c/qt/qtwayland/+/461361

However, thinking about it again, we can still avoid triggering the buggy Qt code path by implementing tdf#144302:

https://gerrit.libreoffice.org/c/core/+/147379
Comment 5 Commit Notification 2023-02-21 08:33:18 UTC
Michael Weghorn committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/db6ed07f4c1a086e4962ff16d3ede9aea9e60952

tdf#144302 tdf#153333 qt: Load cursor from icon theme

It will be available in 7.6.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 Jan Rathmann 2023-02-22 11:40:44 UTC
I can confirm that this is fixed for me in master from today. Thank you very much Michael!
Comment 7 Stéphane Guillou (stragu) 2023-02-22 11:51:12 UTC
thanks Jan and Michael! Marking as Verified for Jan.
Comment 8 Michael Weghorn 2023-02-22 12:30:05 UTC
Thanks for the feedback! FWIW, the Qt bugfix has also been merged today and will be in Qt 6.6.
Comment 9 Commit Notification 2023-02-24 09:14:36 UTC
Michael Weghorn committed a patch related to this issue.
It has been pushed to "libreoffice-7-5":

https://git.libreoffice.org/core/commit/091f56e50748e3fd807b9bae88652b68834aac3a

tdf#144302 tdf#153333 qt: Load cursor from icon theme

It will be available in 7.5.2.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 10 Jan Rathmann 2023-02-25 12:03:06 UTC
I can also confirm that this is fixed in 7.5.2 daily builds.
Comment 11 Stéphane Guillou (stragu) 2023-06-07 13:50:55 UTC
*** Bug 155672 has been marked as a duplicate of this bug. ***
Comment 12 Buovjaga 2023-11-08 08:49:41 UTC
*** Bug 158079 has been marked as a duplicate of this bug. ***