1

Windows have been moving underneath the dock (see attached photo).

I can consistently reproduce the effect by having a maximized window open, locking the screen, and then unlocking it.

Example of the dock overlapping with firefox after locking and unlocking my system

I am using Ubuntu 22.04.3 LTS and Gnome version 42.9. If any other information is helpful please let me know.

I understand this is a duplicate issue but the others have no solution and no steps to reproduce. Without reputation I can't comment steps to reproduce on these posts, so I'm making my own.

  • Great question (I have the same problem), it only misses links to the duplicates. I only found https://ubuntuforums.org/showthread.php?t=2490510 (haven't searched for long) – pHneutre Nov 28 '23 at 09:41
  • Also I'm pretty sure it's a bug and should be reported as such: https://bugs.launchpad.net/ubuntu/ – pHneutre Nov 28 '23 at 09:43

1 Answers1

1

I was able to work around this issue by using the following script:

#!/bin/sh

dbus-monitor --session "type='signal',interface='org.gnome.ScreenSaver'" | while read x; do case "$x" in "boolean true") echo SCREEN_LOCKED;; "boolean false") echo SCREEN_UNLOCKED gnome-extensions disable ubuntu-dock@ubuntu.com sleep 0.5 gnome-extensions enable ubuntu-dock@ubuntu.com esac done

Name it something like fix_dock.sh, add it to "Startup Applications". Whenever the screen locks and then "unlocks", it will disable the dock, wait half a second and then re-enable it. This should realign the windows.

arashb31
  • 111
  • Seems to be working, I'll try to come back to confirm in a few days. After creating the file I executed chmod +x fix_dock.sh, I think it's necessary for the script to execute. Also, I still think this bug should be reported to Ubuntu. – pHneutre Mar 06 '24 at 09:33
  • Yes you're right, You need to make it executable by running the above command. – arashb31 Mar 07 '24 at 02:40
  • It doesn't seem to work properly, some windows still slip under the dock. :( – pHneutre Mar 08 '24 at 12:38
  • I think the window which are minimized when the dock is disabled/re-anabled aren't affected. Maybe you could modify this script so that every window is maximized before? – pHneutre Mar 19 '24 at 09:34