Bug 103174 - Very laggy scrolling with trackpad on hidpi screens
Summary: Very laggy scrolling with trackpad on hidpi screens
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
(earliest affected) release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
Whiteboard: target:5.3.4
Keywords: perf
Depends on:
Blocks: HiDPI GTK3
  Show dependency treegraph
Reported: 2016-10-13 05:44 UTC by François Guerraz
Modified: 2017-06-23 08:39 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:

libreoffice-fresh.csh referenced above (155 bytes, text/plain)
2017-03-15 05:07 UTC, Rich R
libreoffice-fresh.sh (155 bytes, application/x-shellscript)
2017-03-15 05:09 UTC, Rich R

Note You need to log in before you can comment on or make changes to this bug.
Description François Guerraz 2016-10-13 05:44:09 UTC
scrolling with a trackpad in Linux / GTK3 / X11 is really slow, jumps around and even goes in erratic directions. This affects all the apps of the suite.
Comment 1 François Guerraz 2016-10-13 07:36:39 UTC
Launching with SAL_USE_VCLPLUGIN=gtk works around the issue
Comment 2 Buovjaga 2016-10-26 18:50:15 UTC
Which Linux distro, btw.?
Comment 3 Axel 2016-11-29 20:12:11 UTC
I confirm this annoying bug.

Happens only when scrolling with touchpad (mouse wheel scrolling works fine).
It is also fixed by launching env SAL_USE_VCLPLUGIN=gtk libreoffice --writer for example.
I am on Fedora 25 / Gnome DE.
Comment 4 Buovjaga 2016-11-29 20:15:29 UTC
NEW per comment 3
Comment 5 François Guerraz 2016-12-24 15:24:06 UTC
This still affects Version: on arch64 on both Wayland and X11.
Comment 6 François Guerraz 2016-12-25 09:40:22 UTC
Actually, I can't reproduce it any more on GTK3/X11. This seems only to affect GTK3/Wayland.
Comment 7 Rich R 2017-02-07 02:35:32 UTC
I am still getting it on libreoffice 5.3/gtk3/xorg.  The fix in #c1 still works.  will it mess other things up to put the env variable in .bashrc instead of the launcher?
Comment 8 Buovjaga 2017-02-07 07:08:59 UTC
(In reply to Rich R from comment #7)
> I am still getting it on libreoffice 5.3/gtk3/xorg.  The fix in #c1 still
> works.  will it mess other things up to put the env variable in .bashrc
> instead of the launcher?

It should be fine.
Comment 9 Rich R 2017-02-19 22:10:07 UTC
actually this is already covered in the settings but not documented well.  you just need to uncomment the gtk settings in /etc/profile.d/libreoffice-fresh.csh and /etc/profile.d/libreoffice-fresh.sh.  Could this be moved into the options gui? or would the fact that it is linux only that requires it complicate things?  At least it should be better documented, no?  Especially since the settings are already installed but commented out in the profile.d dir.  BTW, the same method works on the "still" version as well as the "fresh" as far as I can tell.  I don't know if this should be marked as resolved or as an enhancement/feature req, maybe moving it to documentation or wherever the help menu is located rather than the graphics stack, since this is a documentation/implementation problem rather than a bug in the graphics stack.  Maybe there is a way to autodetect based on what desktop mgr is loaded?
Comment 10 François Guerraz 2017-02-19 23:21:37 UTC
It's definitely a bug and should be fixed for two reasons:
First, we need gtk3 for wayland support 
Second, "it works if you tweak it" still means that there is a bug as things should work out of the box

Also, I'm going back on my comment that it works on X11, no, it's still bad on X11 with gtk3.
Comment 11 Rich R 2017-02-19 23:44:51 UTC
I've got no horse in this race as I am now in "Works for me" territory :)
Comment 12 Caolán McNamara 2017-02-20 10:31:56 UTC
what is in /etc/profile.d/libreoffice-fresh.csh or /etc/profile.d/libreoffice-fresh.sh because those are provided by your distro so presumably your distro hit upon a workaround and put in it there
Comment 13 François Guerraz 2017-03-04 08:12:32 UTC
@Caolán there's only the export SAL_USE_VCLPLUGIN=gtk I set myself
Comment 14 François Guerraz 2017-03-14 13:22:01 UTC
Could this be related?
Comment 15 Rich R 2017-03-15 05:07:51 UTC
Created attachment 131895 [details]
libreoffice-fresh.csh referenced above

Adding the two arch linux config files that add the variable to fix the problem.  uncomment whichever desktop you are using.  I think I had to do it in both.
Comment 16 Rich R 2017-03-15 05:09:02 UTC
Created attachment 131896 [details]

and the other one.
Comment 17 Rich R 2017-03-15 05:13:24 UTC
@François Guerraz,You asked: 

> Could this be related? https://bugzilla.gnome.org/show_bug.cgi?id=778926

IDK, works for me but I am running xwindows not wayland, and was not having the cpu spike problem mentioned there.
Comment 18 François Guerraz 2017-05-10 13:04:57 UTC
Just writing to report that the problem is still present LO on gtk 3.22.13, still unusable.
(I had hoped that maybe the gtk upgrade would magic the problem away...)
Comment 19 Caolán McNamara 2017-05-22 16:07:34 UTC
This may be the same problem as https://bugzilla.redhat.com/show_bug.cgi?id=1367846 which downstream reports as fixed with some changes I've merged to master which I'll now backport to upstream 5-3
Comment 20 Caolán McNamara 2017-05-22 16:14:48 UTC
https://gerrit.libreoffice.org/#/c/37913/ for 5-3 backport
Comment 21 Commit Notification 2017-05-24 08:42:12 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-5-3":


Resolves: tdf#103174 & rhbz#1367846 improve gtk3 trackpad scrolling

It will be available in 5.3.4.

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

Affected users are encouraged to test the fix and report feedback.
Comment 22 Caolán McNamara 2017-06-22 15:11:08 UTC
downstream feedback suggests that this solves the problem
Comment 23 François Guerraz 2017-06-23 08:39:16 UTC
I confirm that the GTK3 backend is now usable and actually yields better results than GTK. 

Thanks a lot.