Mouse Lag in ubuntu Gnome
Solution 1:
I saw this and I really think it solved my problem on a fresh install of 16.04 LTS:
"https://superuser.com/questions/528727/how-do-i-solve-periodic-mouse-lag-on-linux-mint-mate"
I found this solution! Credit goes to the original poster.
https://superuser.com/questions/528727/how-do-i-solve-periodic-mouse-lag-on-linux-mint-mate
To save some peeps the trouble of going to the link here are the specific instructions I followed (copy and paste each line on a terminal):
sudo su -
modprobe drm_kms_helper
echo N> /sys/module/drm_kms_helper/parameters/poll
echo "drm_kms_helper" >> /etc/modprobe.d/local.conf
echo 'drm_kms_helper' >> /etc/modules-load.d/local.conf
echo "options drm_kms_helper poll=N" >> /etc/modprobe.d/local.conf
Credit goes to the original poster, Mr. Indrek.
Solution 2:
On Lubuntu 19.04, when using a VirtualBox VM on Mac OS, I noticed that only some apps would cause the mouse to lockup. I tried every possible VirtualBox setting test to see if that was it. I then read kernel tricks with the mouse polling and tried that. Nothing worked. I rolled it all back.
That's when I had an epiphany. The apps that were slowing down were MATE-based, such as Pluma, or GTK2 or GTK3 based, such as Chromium (which is GTK3-based). The thing that was slowing it down, I soon realized, was the animation as I moved across items, such as the hidden scrollbar that would appear when the window was hovered, or a slight highlight color when you hover over certain parts of the Pluma editor. This was because the VM was not able to do these animations fast enough.
So, to fix this, I took these steps:
-
Turn on the GTK2 scrollbar so that it doesn't hide and animate:
$ sudo apt-get install overlay-scrollbar-gtk2
-
Install dconf-tools so that you can run dconf-editor (a GUI-based registry kind of app for MATE desktop) as both root and as a normal power user (need to do both) so that you change your MATE settings in both contexts, should you need those.
$ sudo apt-get install dconf-tools
-
Launch dconf-editor first as root (sudo su) and do the following steps, then do it as a regular user. Be sure to click the item, turn off the default value, and then click the custom value. When prompted to apply, do so. It may tell you that change won't take effect until you reboot.
org / gnome / desktop / interface / enable-animations - set to false
org / mate / desktop / interface / enable-animations - set to false
org / mate / desktop / interface / gtk-enable-animations - set to false
org / mate / marco / general / reduced-resources - set to true
You can also try going into Chrome or Chromium with the URL
chrome://flags
, search on "scroll", and disable Smooth Scrolling in order to speed up the scrolling of pages inside a VM if that is running too slowly.
Now, when you reboot, almost all of the animations are off in GTK2, GTK3, and MATE based applications in Lubuntu 19.04, somewhat fixing mouse lag across window elements driven by those window toolkits. Note that not all animations are turned off unfortunately due to some widgets not looking at the animation property in gconf. Also, not all mouse lag is fixed. However, it is greatly improved.
P.S. I'm still investigating if there are other Chromium/Chrome flags (chrome://flags) regarding GPU that I can turn off to make Chromium run faster in a VirtualBox VM on Mac OS. You can try some tests of your own by searching on "gpu" in chrome://flags.