diff --git a/config/hypr/configs/Keybinds.conf b/config/hypr/configs/Keybinds.conf index 39068ee..177861c 100644 --- a/config/hypr/configs/Keybinds.conf +++ b/config/hypr/configs/Keybinds.conf @@ -36,7 +36,8 @@ bind = $mainMod CTRL, S, exec, $scriptsDir/RofiBeats.sh bind = $mainMod ALT, E, exec, $scriptsDir/RofiEmoji.sh bind = $mainMod, H, exec, $scriptsDir/KeyHints.sh bind = $mainMod, E, exec, $scriptsDir/QuickEdit.sh -bind = $mainMod, B, exec, killall -SIGUSR1 waybar # Toggle hide/show waybar +bind = $mainMod SHIFT, B, exec, $scriptsDir/ChangeBlur.sh # Toggle blur settings +bind = $mainMod, B, exec, killall -SIGUSR1 waybar # Toggle hide/show waybar bind = $mainMod SHIFT, G, exec, $scriptsDir/GameMode.sh bind = CTRL SHIFT, W, exec, $scriptsDir/Refresh.sh bind = CTRL ALT, W, exec, $scriptsDir/Wallpaper.sh diff --git a/config/hypr/configs/Settings.conf b/config/hypr/configs/Settings.conf index f0a642c..066998f 100644 --- a/config/hypr/configs/Settings.conf +++ b/config/hypr/configs/Settings.conf @@ -59,8 +59,8 @@ decoration { blur { enabled = true - size = 4 - passes = 1 + size = 6 + passes = 2 ignore_opacity = true new_optimizations = true } diff --git a/config/hypr/scripts/AirplaneMode.sh b/config/hypr/scripts/AirplaneMode.sh index 35fe5db..dc9a595 100755 --- a/config/hypr/scripts/AirplaneMode.sh +++ b/config/hypr/scripts/AirplaneMode.sh @@ -1,9 +1,12 @@ #!/bin/bash + +dunstify -u low -i "$dunst_notif" + wifi="$(nmcli r wifi | awk 'FNR = 2 {print $1}')" if [ "$wifi" == "enabled" ]; then rfkill block all & - dunstify -t 1000 'airplane mode: active' + dunstify -u normal -i "$dunst_notif" -t 1000 'airplane mode: active' else rfkill unblock all & - dunstify -t 1000 'airplane mode: inactive' + dunstify -u normal -i "$dunst_notif" -t 1000 'airplane mode: inactive' fi diff --git a/config/hypr/scripts/ChangeBlur.sh b/config/hypr/scripts/ChangeBlur.sh index 247265f..46d8a1f 100755 --- a/config/hypr/scripts/ChangeBlur.sh +++ b/config/hypr/scripts/ChangeBlur.sh @@ -1,13 +1,15 @@ #!/bin/bash +dunst_notif="$HOME/.config/dunst/images/bell.png" + STATE=$(hyprctl -j getoption decoration:blur:passes | jq ".int") if [ "${STATE}" == "2" ]; then - hyprctl keyword decoration:blur:size 3 + hyprctl keyword decoration:blur:size 2 hyprctl keyword decoration:blur:passes 1 - notify-send "Less blur" + dunstify -u low -i "$dunst_notif" "Less blur" else - hyprctl keyword decoration:blur:size 7.8 + hyprctl keyword decoration:blur:size 6 hyprctl keyword decoration:blur:passes 2 - notify-send "Normal blur" + dunstify -u low -i "$dunst_notif" "Normal blur" fi diff --git a/config/hypr/scripts/ChangeLayout.sh b/config/hypr/scripts/ChangeLayout.sh index 6cb342f..28b7203 100755 --- a/config/hypr/scripts/ChangeLayout.sh +++ b/config/hypr/scripts/ChangeLayout.sh @@ -1,5 +1,7 @@ #!/bin/bash +dunst_notif="$HOME/.config/dunst/images/bell.png" + LAYOUT=$(hyprctl -j getoption general:layout | jq '.str' | sed 's/"//g') case $LAYOUT in @@ -10,7 +12,7 @@ case $LAYOUT in hyprctl keyword bind SUPER,J,cyclenext hyprctl keyword bind SUPER,K,cyclenext,prev hyprctl keyword bind SUPER,O,togglesplit - notify-send "Dwindle Layout" + dunstify -u low -i "$dunst_notif" "Dwindle Layout" ;; "dwindle") hyprctl keyword general:layout master @@ -19,7 +21,7 @@ case $LAYOUT in hyprctl keyword unbind SUPER,O hyprctl keyword bind SUPER,J,layoutmsg,cyclenext hyprctl keyword bind SUPER,K,layoutmsg,cycleprev - notify-send "Master Layout" + dunstify -u low -i "$dunst_notif" "Master Layout" ;; *) ;; diff --git a/config/hypr/scripts/DarkLight.sh b/config/hypr/scripts/DarkLight.sh index 0978c53..628baa4 100755 --- a/config/hypr/scripts/DarkLight.sh +++ b/config/hypr/scripts/DarkLight.sh @@ -149,8 +149,8 @@ ${SCRIPTSDIR}/PywalSwww.sh & sleep 2 ${SCRIPTSDIR}/Refresh.sh -notify-send "GTK theme set to $selected_theme" -notify-send "Icon theme set to $selected_icon" +dunstify -u low -i "$dunst_notif" "GTK theme set to $selected_theme" +dunstify -u low -i "$dunst_notif" "Icon theme set to $selected_icon" exit 0 diff --git a/config/hypr/scripts/GameMode.sh b/config/hypr/scripts/GameMode.sh index ecdcfb8..50aed7c 100755 --- a/config/hypr/scripts/GameMode.sh +++ b/config/hypr/scripts/GameMode.sh @@ -1,16 +1,27 @@ #!/bin/bash + +dunst_notif="$HOME/.config/dunst/images/bell.png" +SCRIPTSDIR="$HOME/.config/hypr/scripts" + + HYPRGAMEMODE=$(hyprctl getoption animations:enabled | awk 'NR==2{print $2}') if [ "$HYPRGAMEMODE" = 1 ] ; then hyprctl --batch "\ keyword animations:enabled 0;\ keyword decoration:drop_shadow 0;\ - keyword decoration:blur 0;\ + keyword decoration:blur:passes 0;\ keyword general:gaps_in 0;\ keyword general:gaps_out 0;\ keyword general:border_size 1;\ keyword decoration:rounding 0" swww kill - notify-send "animations off" + dunstify -u low -i "$dunst_notif" "animations off" + exit +else + swww init && swww img "$HOME/.config/rofi/.current_wallpaper" + sleep 0.5 + ${SCRIPTSDIR}/RefreshNoWaybar.sh + dunstify -u low -i "$dunst_notif" "Animations turned on" exit fi -hyprctl reload +hyprctl reload diff --git a/config/hypr/scripts/KeyHints.sh b/config/hypr/scripts/KeyHints.sh index 6017140..b2c506f 100755 --- a/config/hypr/scripts/KeyHints.sh +++ b/config/hypr/scripts/KeyHints.sh @@ -36,7 +36,7 @@ yad --width=$dynamic_width --height=$dynamic_height \ --column=Command: \ --timeout=60 \ --timeout-indicator=bottom \ -"ESC" "close this app" "" "=" "SUPER KEY" "(SUPER KEY)" \ +"ESC" "close this app" "" "=" "SUPER KEY (Windows Key)" "(SUPER KEY)" \ " enter" "Terminal" "(kitty)" \ " or  D" "App Launcher" "(rofi)" \ " T" "Open File Manager" "(Thunar)" \ @@ -45,8 +45,9 @@ yad --width=$dynamic_width --height=$dynamic_height \ " W" "Choose wallpaper" "(swww)" \ "CTRL ALT W" "Random wallpaper" "(swww)" \ "CTRL W" "Choose waybar styles" "(waybar styles)" \ +" B" "Hide/UnHide Waybar" "waybar" \ "ALT W" "Choose waybar layout" "(waybar layout)" \ -"CTRL SHIFT W" "Reload Waybar and Dunst" "" \ +"CTRL SHIFT W" "Reload Waybar Dunst Rofi" "" \ " Print" "screenshot" "(grim)" \ " Shift Print" "screenshot region" "(grim + slurp)" \ " Shift S" "screenshot region" "(swappy)" \ @@ -57,6 +58,7 @@ yad --width=$dynamic_width --height=$dynamic_height \ " Spacebar" "Toggle Dwindle | Master Layout" "Hyprland Layout" \ " Shift F" "Toggle float" "single window" \ " ALT F" "Toggle all windows to float" "all windows" \ +" Shift B" "Toggle Blur" "normal or less blur" \ " SHIFT G" "Gamemode! All animations off" "" \ " H" "Launch this app" "" \ " E" "View or EDIT Keybinds, Settings, Monitor" "" \ diff --git a/config/hypr/scripts/Refresh.sh b/config/hypr/scripts/Refresh.sh index 0d91de8..c9ad2a6 100755 --- a/config/hypr/scripts/Refresh.sh +++ b/config/hypr/scripts/Refresh.sh @@ -18,6 +18,9 @@ sleep 0.1 # Relaunch dunst with pywal-borders ${SCRIPTSDIR}/PywalDunst.sh & +# Pywal refresh +${SCRIPTSDIR}/PywalSwww.sh & + # Relaunching rainbow borders sleep 1 ${SCRIPTSDIR}/RainbowBorders.sh & diff --git a/config/hypr/scripts/RofiBeats.sh b/config/hypr/scripts/RofiBeats.sh index f7d7074..e0cc6f7 100755 --- a/config/hypr/scripts/RofiBeats.sh +++ b/config/hypr/scripts/RofiBeats.sh @@ -21,7 +21,7 @@ declare -A menu_options=( # Function for displaying notifications notification() { - dunstify -h string:x-canonical-private-synchronous:sys-notify -u normal -i "$iDIR/music.png" "Playing now: $@" + dunstify -u normal -i "$iDIR/music.png" "Playing now: $@" } # Main function @@ -45,4 +45,4 @@ main() { } # Check if an online music process is running and send a notification, otherwise run the main function -pkill -f http && dunstify -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/music.png" "Online Music stopped" || main +pkill -f http && dunstify -u low -i "$iDIR/music.png" "Online Music stopped" || main diff --git a/config/hypr/scripts/TouchPad.sh b/config/hypr/scripts/TouchPad.sh index 09dc563..8f633ee 100755 --- a/config/hypr/scripts/TouchPad.sh +++ b/config/hypr/scripts/TouchPad.sh @@ -1,8 +1,9 @@ #!/bin/bash +dunst_notif="$HOME/.config/dunst/images/bell.png" + # NOTE: find the right device using hyprctl devices - -HYPRLAND_DEVICE="asue1209:00-04f3:319f-touchpad" + HYPRLAND_DEVICE="asue1209:00-04f3:319f-touchpad" if [ -z "$XDG_RUNTIME_DIR" ]; then export XDG_RUNTIME_DIR=/run/user/$(id -u) @@ -13,7 +14,7 @@ export STATUS_FILE="$XDG_RUNTIME_DIR/touchpad.status" enable_touchpad() { printf "true" > "$STATUS_FILE" - notify-send -u normal "Enabling Touchpad" + dunstify -u low -i "$dunst_notif" "Enabling Touchpad" hyprctl keyword "device:$HYPRLAND_DEVICE:enabled" true } @@ -21,7 +22,7 @@ enable_touchpad() { disable_touchpad() { printf "false" > "$STATUS_FILE" - notify-send -u normal "Disabling Touchpad" + dunstify -u low -i "$dunst_notif" "Disabling Touchpad" hyprctl keyword "device:$HYPRLAND_DEVICE:enabled" false } diff --git a/config/hypr/scripts/Volume.sh b/config/hypr/scripts/Volume.sh index a51999d..6a50cb7 100755 --- a/config/hypr/scripts/Volume.sh +++ b/config/hypr/scripts/Volume.sh @@ -30,29 +30,35 @@ notify_user() { # Increase Volume inc_volume() { - pamixer -i 5 && notify_user + if [ "$(pamixer --get-mute)" == "true" ]; then + pamixer -u && notify_user + fi + pamixer -i 5 && notify_user } # Decrease Volume dec_volume() { - pamixer -d 5 && notify_user + if [ "$(pamixer --get-mute)" == "true" ]; then + pamixer -u && notify_user + fi + pamixer -d 5 && notify_user } # Toggle Mute toggle_mute() { if [ "$(pamixer --get-mute)" == "false" ]; then - pamixer -m && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/volume-mute.png" "Volume Switched OFF" + pamixer -m && dunstify -u low -i "$iDIR/volume-mute.png" "Volume Switched OFF" elif [ "$(pamixer --get-mute)" == "true" ]; then - pamixer -u && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$(get_icon)" "Volume Switched ON" + pamixer -u && dunstify -u low -i "$(get_icon)" "Volume Switched ON" fi } # Toggle Mic toggle_mic() { if [ "$(pamixer --default-source --get-mute)" == "false" ]; then - pamixer --default-source -m && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/microphone-mute.png" "Microphone Switched OFF" + pamixer --default-source -m && dunstify -u low -i "$iDIR/microphone-mute.png" "Microphone Switched OFF" elif [ "$(pamixer --default-source --get-mute)" == "true" ]; then - pamixer -u --default-source u && notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$iDIR/microphone.png" "Microphone Switched ON" + pamixer -u --default-source u && dunstify -u low -i "$iDIR/microphone.png" "Microphone Switched ON" fi } # Get icons @@ -75,12 +81,18 @@ notify_mic_user() { # Increase MIC Volume inc_mic_volume() { - pamixer --default-source -i 5 && notify_mic_user + if [ "$(pamixer --default-source --get-mute)" == "true" ]; then + pamixer --default-source -u && notify_mic_user + fi + pamixer --default-source -i 5 && notify_mic_user } # Decrease MIC Volume dec_mic_volume() { - pamixer --default-source -d 5 && notify_mic_user + if [ "$(pamixer --default-source --get-mute)" == "true" ]; then + pamixer --default-source -u && notify_mic_user + fi + pamixer --default-source -d 5 && notify_mic_user } # Execute accordingly diff --git a/config/hypr/scripts/Wallpaper.sh b/config/hypr/scripts/Wallpaper.sh index c203ce2..e670dc6 100755 --- a/config/hypr/scripts/Wallpaper.sh +++ b/config/hypr/scripts/Wallpaper.sh @@ -18,7 +18,6 @@ SWWW_PARAMS="--transition-fps $FPS --transition-type $TYPE --transition-duration swww query || swww init && swww img ${RANDOMPICS} $SWWW_PARAMS -${SCRIPTSDIR}/PywalSwww.sh & sleep 1 ${SCRIPTSDIR}/Refresh.sh diff --git a/config/hypr/scripts/WallpaperSelect.sh b/config/hypr/scripts/WallpaperSelect.sh index 16790bd..61049e5 100755 --- a/config/hypr/scripts/WallpaperSelect.sh +++ b/config/hypr/scripts/WallpaperSelect.sh @@ -80,6 +80,5 @@ fi main -${SCRIPTSDIR}/PywalSwww.sh & sleep 1 ${SCRIPTSDIR}/Refresh.sh