Dwm + systray + picom

I finally managed to get picom working correctly with dwm and the systray. Previously picom would recognise the systray as it’s own window and add a shadow around it. Thanks to Bakkeby from Reddit, that is sorted.

I’m not sure why I didn’t come across this earlier. Also, this works on my dwm-6.2 build not sure if it will for 6.3 and 6.4.

3 Likes

What other patches are you using?

2 Likes

It works on patched dwm 6.4

dwm-attachaside-6.3.diff
dwm-cool-autostart-6.2.diff
dwm-focusonclick-20200110-61bb8b2.diff
dwm-gaplessgrid-20160731-56a31dc.diff
dwm-moveresize-20210823-a786211.diff
dwm-notitle-6.2.diff
dwm-pertag-20200914-61bb8b2.diff
dwm-statusbutton-20180524-c8e9479.diff
dwm-systray-6.3.diff
dwm-uselessgap-20211119-58414bee958f2.diff
1 Like

Did you try to add this line is shadow-exclude?

"class_g = 'dwm'"

I don’t use picom in dwm. Didn’t test it myself.

1 Like

I already had that. Because of the way the systemtray is created, that configuration has no effect. So add the couple lines of code from the link @Dobbie03 provided and recompile.

Normally I use a picom.dwm file for dwm with shadows set to false. Just transparent terminals; mostly for screenshots.

1 Like

These and a few more that I forgot to add to the list. I’m not using the anybar patch on this one though.

Yes, that never worked, I always used xcompmgr as a workaround for compositing. Felt like some decent shadows today so that’s why Iooked into Picom again.

1 Like

My picom.conf
shadow = true;
shadow-radius = 12;
shadow-offset-x = -5;
shadow-offset-y = -5;
shadow-opacity = 0.5;

shadow-exclude = [
“! name~=‘’”,
“name = ‘Notification’”,
“name = ‘lemonbar’”,
“name = ‘Docky’”,
“name = ‘Kupfer’”,
“name = ‘xfce4-notifyd’”,
“name = ‘cpt_frame_window’”,
“name *= ‘VLC’”,
“name *= ‘compton’”,
“name *= ‘picom’”,
“name *= ‘Chromium’”,
“name *= ‘Chrome’”,
“class_g = ‘Firefox’ && argb”,
“class_g = ‘Conky’”,
“class_g = ‘Kupfer’”,
“class_g = ‘Synapse’”,
“class_g ?= ‘Notify-osd’”,
“class_g ?= ‘Cairo-dock’”,
“class_g ?= ‘Xfce4-notifyd’”,
“class_g ?= ‘Xfce4-power-manager’”,
“_GTK_FRAME_EXTENTS@:c”,
“_NET_WM_STATE@:32a *= ‘_NET_WM_STATE_HIDDEN’”
];

This never worked for, even though it was offered as an alternative to patching the dwm build.

1 Like

Need to look into NET_WM_STATE as it was a command that was already included with picom.conf file.

Thanks for pointing this out :+1:

_NET_WM_STATE_HIDDEN should be enabled when window isn’t visible in any active workspace