1
0
Fork 0
This commit is contained in:
Luca Bilke 2023-03-20 10:15:16 +01:00
parent 32528f71d7
commit 4e67ab258e
3 changed files with 11 additions and 12 deletions

View file

@ -2,6 +2,6 @@ default xkb_keymap {
xkb_keycodes { include "evdev+aliases(qwerty)" };
xkb_types { include "complete" };
xkb_compat { include "complete" };
xkb_symbols { include "pc+us(dvorak)+inet(evdev)+custom(caps_mod4)+custom(ralt_mod3)+custom(group2_dvorak)" };
xkb_symbols { include "pc+us(dvorak)+inet(evdev)+capslock(super)+custom(ralt_mod3)+custom(group2_dvorak)" };
xkb_geometry { include "pc(pc105)" };
};

View file

@ -14,6 +14,7 @@ export XSECURELOCK_NO_COMPOSITE=1
[ -r "/usr/lib/xscreensaver/cubicgrid" ] && export XSECURELOCK_SAVER="/usr/lib/xscreensaver/cubicgrid"
export XSECURELOCK_SHOW_DATETIME=1
export XSECURELOCK_SHOW_HOSTNAME=1
export XSECURELOCK_SHOW_KEYBOARD_LAYOUT=0
xset s 300
xss-lock -l -- xsecurelock &

View file

@ -9,25 +9,23 @@ pamixer "$@" >/dev/null
# Query amixer for the current volume and whether or not the speaker is muted
volume="$(pamixer --get-volume)"
mute="$(pamixer --get-mute)"
[ "$volume" -gt "100" ] && highlight="#ff768e" || highlight="#7aa2f7"
if [ "$volume" -gt "70" ]; then
if [ "$mute" = "true" ]; then
icon="audio-volume-muted"
elif [ "$volume" -gt "70" ]; then
icon="audio-volume-high"
elif [ "$volume" -gt "30" ]; then
icon="audio-volume-medium"
elif [ "$volume" -gt "0" ]; then
elif [ "$volume" -ge "0" ]; then
icon="audio-volume-low"
fi
mute="$(pamixer --get-mute)"
if [ "$volume" = 0 ] || [ "$mute" = "true" ]; then
notify-send -a "changeVolume" -i "audio-volume-muted" -u low -h string:x-dunst-stack-tag:$msgTag "Volume muted"
else
notify-send -a "changeVolume" -i "$icon" -u low "Volume: ${volume}%"\
-h string:x-dunst-stack-tag:$msgTag \
-h int:value:$volume \
-h string:hlcolor:$highlight
fi
notify-send -a "changeVolume" -i "$icon" -u low "Volume: ${volume}%" \
-h string:x-dunst-stack-tag:$msgTag \
-h int:value:$volume \
-h string:hlcolor:$highlight
# Play the volume changed sound
canberra-gtk-play -i audio-volume-change -d "changeVolume"