Various problems in Manjaro KDE after wake-from-sleep

Hi guys. I’ve been having a lot of issues with my Manjaro KDE install recently and I need help figuring out firstly if it’s Manjaro, Plasma, or SDDM, and secondly, how to fix it.

I’ll start this with some system info. I have 2 monitors, a left and right one. the right one is my main monitor, but I think the left one technically has higher priority, because on a fresh install (of windows, linux, anything) the left monitors defaults to the primary. I have the right one set as the primary in Plasma, however. As for the rest of the system, I’ll just paste the “about this system” from settings:

Operating System: Manjaro Linux
KDE Plasma Version: 5.24.4
KDE Frameworks Version: 5.92.0
Qt Version: 5.15.3
Kernel Version: 5.15.32-1-MANJARO (64-bit)
Graphics Platform: X11
Processors: 16 × AMD Ryzen 7 3700X 8-Core Processor
Memory: 15.6 GiB of RAM
Graphics Processor: NVIDIA GeForce GTX 1660 Ti/PCIe/SSE2

Anyways, system info aside, my issues; after sleep, I experience several problems:

  • Unfocused windows do not re-focus, and re-scaling them breaks the border entirely.
    Here’s a konsole window focused:

    and here’s that same window when I try to fullscreen it:

    this only seems to affect windows using the standard window borders, as programs like Firefox using the native titlebar are unaffected. Any programs I open post-wake are also unaffected.

  • Windows shift to the left monitor after wake.
    Like I said, the left monitor seems to be seen as the “primary” in some sense. (for instance, when I wake from sleep, my cursor and keyboard are focused on the left monitor; I don’t see that as a bug, since I assume SDDM just isn’t being told to primary the right monitor like Plasma is.) Logging in after wake, any windows I had focused on the primary right monitor (i.e. Firefox) are moved to the left, where programs already on the left monitor (i.e. Discord) stay there. This is true for maximized and windowed programs.

  • Brightness / night color settings do not fix on both monitors.
    I have monitor brightness setup via ddc/ci, and Plasma will dim my monitors before going to sleep, similar to a laptop. however, after wake, it seems that the brightness on the left monitor gets restored to what is was pre-dimming, whereas the right monitor stays at 0% until I manually adjust it. Similarly, I had “night color” on in Plasma, which just applies the orange screen tint based on sunrise/sunset. When I manually enable/disable it, it makes no difference, neither display reflects the changes. However, with night color enabled, despite showing no change initially, after wake, the left monitor has a permanent orange hue until I restart the PC. I have only recently experienced this, since I only accidentally left night mode on by accident (like I said, it doesn’t make any difference when initially enabled). As such, I haven’t had much a chance to play with this as the other issues. However, I do find it interesting that after wake, night mode fails to update on the left monitor, and brightness settings fail to update on the right.

  • Program preview crashes Plasma widget
    This one is probably the most minor, but it’s still odd. After wake, I seemingly don’t have any compositor issues (I remember that being the case on an old install). However, the first time I hover over a program on my task manager to see the preview, it crashes the entire Plasma panel, and after a couple seconds, the panel comes back, and I can hover to preview just fine.

Those are all the issues I can think of off the top of my head. They’re mostly minor annoyances, nothing that forces a system reboot, but I would like to resolve them if possible. I tried to provide as much info as I can but if there’s anything else I can clarify on, I’m more than happy to. I can try to capture video examples of some issues as well, if that would help.

Please let me know of any way I can fix one or all of these issues. Thank you!

provide output from:
inxi -Fazy
mhwd -l
mhwd -li
but kde + dual monitors + nvidia = :poop:

not sure if there’s a way to spoiler in this forum, so sorry it’s a bit of a wall

  Kernel: 5.15.32-1-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 11.2.0
    parameters: BOOT_IMAGE=/boot/vmlinuz-5.15-x86_64
    root=UUID=d54c28e0-b68b-414d-8a8f-9a94a6fe9660 rw quiet apparmor=1
    security=apparmor udev.log_priority=3
  Desktop: KDE Plasma v: 5.24.4 tk: Qt v: 5.15.3 wm: kwin_x11 vt: 1 dm: SDDM
    Distro: Manjaro Linux base: Arch Linux
  Type: Desktop System: Gigabyte product: B450 AORUS PRO WIFI v: N/A
    serial: <superuser required>
  Mobo: Gigabyte model: B450 AORUS PRO WIFI-CF v: x.x
    serial: <superuser required> UEFI: American Megatrends v: F50
    date: 11/27/2019
  Info: model: AMD Ryzen 7 3700X bits: 64 type: MT MCP arch: Zen 2
    family: 0x17 (23) model-id: 0x71 (113) stepping: 0 microcode: 0x8701013
  Topology: cpus: 1x cores: 8 tpc: 2 threads: 16 smt: enabled cache:
    L1: 512 KiB desc: d-8x32 KiB; i-8x32 KiB L2: 4 MiB desc: 8x512 KiB
    L3: 32 MiB desc: 2x16 MiB
  Speed (MHz): avg: 3147 high: 4326 min/max: 2200/4426 boost: enabled
    scaling: driver: acpi-cpufreq governor: schedutil cores: 1: 4225 2: 4306
    3: 3196 4: 4203 5: 2090 6: 4190 7: 2169 8: 2486 9: 4292 10: 3351 11: 2405
    12: 2137 13: 2167 14: 4326 15: 2458 16: 2362 bogomips: 115027
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: spec_store_bypass
    mitigation: Speculative Store Bypass disabled via prctl and seccomp
  Type: spectre_v1
    mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2
    mitigation: Retpolines, IBPB: conditional, STIBP: conditional, RSB filling
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
  Device-1: NVIDIA TU116 [GeForce GTX 1660 Ti] vendor:
    driver: nvidia v: 510.60.02 alternate: nouveau,nvidia_drm pcie: gen: 1
    speed: 2.5 GT/s lanes: 16 link-max: gen: 3 speed: 8 GT/s bus-ID: 06:00.0
    chip-ID: 10de:2182 class-ID: 0300
  Display: x11 server: X.Org v: with: Xwayland v: 22.1.1
    compositor: kwin_x11 driver: X: loaded: nvidia gpu: nvidia display-ID: :0
    screens: 1
  Screen-1: 0 s-res: 3840x1080 s-dpi: 91 s-size: 1070x301mm (42.13x11.85")
    s-diag: 1112mm (43.76")
  Monitor-1: DP-0 pos: primary,right res: 1920x1080 dpi: 93
    size: 527x296mm (20.75x11.65") diag: 604mm (23.8") modes: N/A
  Monitor-2: HDMI-0 pos: primary,left res: 1920x1080 dpi: 93
    size: 527x296mm (20.75x11.65") diag: 604mm (23.8") modes: N/A
  OpenGL: renderer: NVIDIA GeForce GTX 1660 Ti/PCIe/SSE2
    v: 4.6.0 NVIDIA 510.60.02 direct render: Yes
  Device-1: NVIDIA TU116 High Definition Audio vendor:
    driver: snd_hda_intel v: kernel pcie: gen: 3 speed: 8 GT/s lanes: 16
    bus-ID: 06:00.1 chip-ID: 10de:1aeb class-ID: 0403
  Device-2: AMD Starship/Matisse HD Audio vendor: Gigabyte
    driver: snd_hda_intel v: kernel pcie: gen: 4 speed: 16 GT/s lanes: 16
    bus-ID: 08:00.4 chip-ID: 1022:1487 class-ID: 0403
  Sound Server-1: ALSA v: k5.15.32-1-MANJARO running: yes
  Sound Server-2: JACK v: 1.9.20 running: no
  Sound Server-3: PulseAudio v: 15.0 running: yes
  Sound Server-4: PipeWire v: 0.3.49 running: yes
  Device-1: Intel I211 Gigabit Network vendor: Gigabyte driver: igb v: kernel
    pcie: gen: 1 speed: 2.5 GT/s lanes: 1 port: f000 bus-ID: 03:00.0
    chip-ID: 8086:1539 class-ID: 0200
  IF: eno1 state: up speed: 1000 Mbps duplex: full mac: <filter>
  Device-2: Intel Dual Band Wireless-AC 3168NGW [Stone Peak] driver: iwlwifi
    v: kernel pcie: gen: 1 speed: 2.5 GT/s lanes: 1 bus-ID: 04:00.0
    chip-ID: 8086:24fb class-ID: 0280
  IF: wlp4s0 state: down mac: <filter>
  Device-1: Intel Wireless-AC 3168 Bluetooth type: USB driver: btusb v: 0.8
    bus-ID: 1-5:2 chip-ID: 8087:0aa7 class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 4 state: up address: see --recommends
  Local Storage: total: 3.39 TiB used: 1.49 TiB (44.0%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/sda maj-min: 8:0 vendor: Seagate model: ST2000DM008-2FR102
    size: 1.82 TiB block-size: physical: 4096 B logical: 512 B speed: 6.0 Gb/s
    type: HDD rpm: 7200 serial: <filter> rev: 0001 scheme: GPT
  ID-2: /dev/sdb maj-min: 8:16 vendor: Seagate model: ST1000DM003-1SB102
    size: 931.51 GiB block-size: physical: 4096 B logical: 512 B speed: 6.0 Gb/s
    type: HDD rpm: 7200 serial: <filter> rev: HPH3 scheme: GPT
  ID-3: /dev/sdc maj-min: 8:32 vendor: Kingston model: SA400S37240G
    size: 223.57 GiB block-size: physical: 512 B logical: 512 B speed: 6.0 Gb/s
    type: SSD serial: <filter> rev: 0102 scheme: GPT
  ID-4: /dev/sdd maj-min: 8:48 vendor: Western Digital
    model: WDS240G2G0B-00EPW0 size: 223.57 GiB block-size: physical: 512 B
    logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter> rev: 0400
    scheme: GPT
  ID-5: /dev/sde maj-min: 8:64 type: USB vendor: SanDisk model: USB 3.2Gen1
    size: 232.88 GiB block-size: physical: 512 B logical: 512 B type: N/A
    serial: <filter> rev: 1.00 scheme: MBR
  SMART Message: Unknown USB bridge. Flash drive/Unsupported enclosure?
  ID-1: / raw-size: 223.27 GiB size: 218.71 GiB (97.96%)
    used: 106.5 GiB (48.7%) fs: ext4 dev: /dev/sdd2 maj-min: 8:50
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
    used: 288 KiB (0.1%) fs: vfat dev: /dev/sdd1 maj-min: 8:49
  Alert: No swap data was found.
  System Temperatures: cpu: N/A mobo: N/A gpu: nvidia temp: 35 C
  Fan Speeds (RPM): N/A gpu: nvidia fan: 0%
  Processes: 602 Uptime: 3d 6h 47m wakeups: 4 Memory: 15.63 GiB
  used: 8.13 GiB (52.0%) Init: systemd v: 250 tool: systemctl Compilers:
  gcc: 11.2.0 clang: 13.0.1 Packages: pacman: 1501 lib: 405 flatpak: 0
  Shell: Bash v: 5.1.16 running-in: konsole inxi: 3.3.15
[shawn@shawn-manjaro ~]$ mhwd -l
> 0000:06:00.0 (0300:10de:2182) Display controller nVidia Corporation:
                  NAME               VERSION          FREEDRIVER           TYPE
          video-nvidia            2021.12.18               false            PCI
    video-nvidia-470xx            2021.12.18               false            PCI
           video-linux            2018.05.04                true            PCI
     video-modesetting            2020.01.13                true            PCI
            video-vesa            2017.03.12                true            PCI

[shawn@shawn-manjaro ~]$ mhwd -li
> Installed PCI configs:
                  NAME               VERSION          FREEDRIVER           TYPE
          video-nvidia            2021.12.18               false            PCI

Warning: No installed USB configs!

unfortunately, that was a bit of a fear of mine, it chalking up to being nvidia. maybe this will finally just push me to get a single ultrawide instead, lol

yes having only one monitor would be probably the best…
try disabling compositor with alt + shift + f12 put your pc to sleep, wake it up, enable compositor with the shortcut again and check if you have issues

it, kind of worked? i disabled the compositor, slept and woke, and windows had no top bar. upon re-enabling compositor window borders look like this:

something else, but still not quite right

maybe its your custom themes… first log out, log in, go to system settings/ global theme click defaults, click apply … put your pc into sleep, wake up, this time keep compositor enabled…

1 Like

huh, sure enough i gave it a shot, and it looks like that’s fixed at least the window border scaling issues.

in that case, would this be an issue with the specific theme, using a non-system theme, or something else?
Basically, can I continue to have scaling work without having to use breeze lol

edit: for the most part, though this might be more a gtk thing. (firefox in screenshot)

for the gtk bug, go to system settings/ application style/ configure gnome-gtk … and select for example breeze, click apply … again put your pc into sleep, wake up and check if everything works

mkay, that’s seemed to fix the gtk bug, ty

do you know if it will be possible to get my other themes working, what might cause it to not work with downloaded themes? Again, I’m glad it’s working with Breeze, but I don’t really want to use Breeze, lol

btw, I tested, this happens with Sweet KDE, ChromeOS-Dark, and it would happen with WhiteSur on my last install. Is it maybe something w/ the process of downloading themes through the built-in GUI in Plasma?

dont use system settings/ global themes/ get new global themes … if you are using this, delete all themes that you downloaded in the global themes… you have to delete them, by clicking on the ‘get new global themes’ and there select ‘show only installed entries’ and delete them … after they are deleted, you can download from each section: plasma style/ colors/ icons, etc… the themes you want… after setting your theme from those sections, again, put your pc to sleep and check

tried this with the chromeos theme I was using, no luck… However, I noticed that after uninstalling the global theme, all the individual parts (cursor, window decorations, etc) were still installed. I tried uninstalling and re-installing just to be sure, but it was still having the issue upon wake.
For the sake of completess I also downloaded a random window decoration that I didnt have any global theme for at any point (just one of the ones at the top of “most recent”), applied the decoration, logged out, logged in, and put to sleep… upon wake, it did the same thing as when I disabled the compositor:

so again go to system settings and go trough global theme/ plasma style/ colors/ window decorations/ icons/ cursors … and in each of those section click on the get new button, in the window click everything and select show only installed and delete all of installed themes and their parts… when youre done, clear kde cache with this command:
rm -rf ~/.cache/*
go again to system settings/ plasma style/ colors/ window decorations and download the sweet theme parts for example, and again put your pc to sleep and check

followed all this, however problem still persists.

interesting sidenote, might be useful to mention: i cannot “uninstall” sweet global theme. applying it changes the theme, but def not to sweet.

this is supposed to be w/ sweet global theme applied.

you can see here, it doesnt show sweet or any other global themes as being installed.

i see, so go to home/.kde4/share/apps/ color schemes and delete all of them
go to home/.local/share/ color schemes and delete them
home/.local/share/plasma/destktop theme and delete them
home/.themes - maybe youll not have this folder
after you delete those files, clear cache: rm -rf ~/.cache/*
reboot and try again system settings/ plasma style/ colors/ window decorations and download the sweet theme parts for example, and again put your pc to sleep and check

issue still persists.
I noticed after deleting the contents of those two directories (i did not have ~/.themes) & rebooting , i still had theme files showing in plasma settings, so i deleted those via gui, cleared cache, and rebooted again.
perhaps theres more directories i need to remove?
but overall i still find it very strange this happens and I almost wonder if it’s more of a failiure-to-load-files thing on boot, rather than just bad files? maybe i just need to use chmod on a specific directory, or use a daemon to restart compositor on boot?
I also feel bad for making you go through all this effort to help, even though its very much appreciated lol

so if you open system settings/ global themes there are no custom themes there anymore, only the default ones?

now yes, however if i were to re-install from the gui and remove from those directories it does not seem to get rid of the global themes in the gui.
looking into it, it looks like my download themes go to ~/.local/share/plasma/look-and-feel/
manually removing them from there and re-installing makes no difference, however.

navigate to:
~/.kde4/share/apps/desktoptheme … are there any themes? if so delete them

nope, i only have a color-schemes in that directory.

so i just downloaded a global theme and its saved in here:
/home/.local/share/plasma/look-and-feel - use dolphin to navigate there and delete everything in that folder