Ubuntu – Volume and brighness adjustment OSD delay and screen freeze on Ubuntu 18.04

18.04gnome-shellnotify-osdnvidia

Every time I raise/lower the volume, or change screen brightness through the keyboard, the screen freezes for 1 to 2 seconds before the corresponding OSD appears and shows the change. It didn't happen on 16.04 – started on 18.04.

If I do the same command in the next couple seconds the freeze doesn't happen (the OSD is fast as it should be).

My computer is new (16G RAM, i7-8750H, nVIDIA GTX 1050ti). The problem happens exclusively on Gnome Shell + Xorg combination – if using cinnamon or Gnome Shell + Wayland it works as expected (but both options have their downsides too, so I prefer to stick with Gnome shell). Any ideas of why this is happening? It gets pretty annoying over time 🙁

Thank you!

Best Answer

The accepted answer to this other question of mine https://askubuntu.com/a/1163929/834984 also solved this problem.

Copied below the relevant part of the answer: "After some digging i found out the culprit is the ScrollLock key and that can be fixed by editing the layout file, which in my case is found at /usr/share/X11/xkb/symbols/br. The only modification i did was to remove or comment the line: modifier_map Mod3 { Scroll_Lock }; After that, set the language and layout back to Portugues (Brasil) and the problem was gone!"

Thank you Gustavo Silva