Debian Compton支持多显示器,配置步骤如下:
安装Compton:
sudo apt update && sudo apt install compton
配置显示器:
xrandr
设置显示器分辨率和位置(如扩展模式):xrandr --output HDMI-1 --auto --right-of eDP-1
~/.config/compton.conf
中添加显示器配置(可选):xrandr-output "HDMI-1" "eDP-1"
启动Compton:
compton -c ~/.config/compton.conf
开机自启动:
创建systemd服务文件/etc/systemd/system/compton.service
,添加以下内容:
[Unit]
Description=Compton Compositor
After=display-manager.service
[Service]
ExecStart=/usr/bin/compton -c ~/.config/compton.conf
Restart=on-failure
[Install]
WantedBy=multi-user.target
然后执行:
sudo systemctl enable compton.service
sudo systemctl start compton.service
注意:确保显卡驱动支持OpenGL,NVIDIA用户需安装nvidia-settings
并配置Xorg。如遇问题,可查看日志~/.cache/compton.log
。