在Compton配置文件(通常位于~/.config/compton.conf
)中設置陰影效果,需添加以下參數:
shadow = true
。shadow-opacity
(0.0-1.0,如0.5
表示半透明)。shadow-radius
(數值越大越模糊,如5
或10
)。shadow-offset-x
和shadow-offset-y
(單位為像素,如2
表示向右下偏移2像素)。shadow-exclude
(通過窗口類名、名稱等排除,如"class_g = 'Firefox'"
)。修改后需重啟Compton生效,命令為:killall compton && compton -c ~/.config/compton.conf
。
參考來源: