-
Notifications
You must be signed in to change notification settings - Fork 25
Per output background example
Jovan Lanik edited this page Jul 11, 2023
·
2 revisions
This example is adapted from https://github.com/jovanlanik/gtklock/issues/16#issuecomment-1155142522.
- lock.sh (somewhere in $PATH)
#!/bin/sh
for o in HDMI-A-2 DP-1 eDP-1
do
grim -o "$o" "/tmp/$o.png"
corrupter "/tmp/$o.png" "/tmp/$o.png" &
done
wait
exec gtklock -s ~/.config/gtklock/style.css "$@"
- style.css (by default ~/.config/gtklock/style.css)
window#HDMI-A-2 {
background-image: url("/tmp/HDMI-A-2.png");
}
window#DP-1 {
background-image: url("/tmp/DP-1.png");
}
window#eDP-1 {
background-image: url("/tmp/eDP-1.png");
}
#window-box {
padding: 64px;
border: 1px solid black;
border-radius: 4px;
box-shadow: rgba(0, 0, 0, 0.5) 0px 4px 12px;
background-color: white;
}