From 7d2a0adbd7836ee4f931128dfdc80a0bad68fcb3 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Thu, 27 Feb 2025 23:10:47 +0900 Subject: returning my old wlogout style :) --- config/hypr/scripts/KeyHints.sh | 1 - config/hypr/scripts/Wlogout.sh | 57 +++++++++++++++++++++++++++++++++++++++-- config/wlogout/style.css | 16 +++++------- 3 files changed, 61 insertions(+), 13 deletions(-) diff --git a/config/hypr/scripts/KeyHints.sh b/config/hypr/scripts/KeyHints.sh index 973ca6b6..2bab4b38 100755 --- a/config/hypr/scripts/KeyHints.sh +++ b/config/hypr/scripts/KeyHints.sh @@ -67,7 +67,6 @@ GDK_BACKEND=$BACKEND yad \ " CTRL Shift R" "Rofi Themes Menu v2" "Choose Rofi Themes via Theme Selector (modified)" \ " SHIFT G" "Gamemode! All animations OFF or ON" "toggle" \ " ALT E" "Rofi Emoticons" "Emoticon" \ -" ALT V" "Clipboard Manager" "cliphist" \ " H" "Launch this Quick Cheat Sheet" "" \ "" "" "" \ "More tips:" "https://github.com/JaKooLit/Hyprland-Dots/wiki" ""\ \ No newline at end of file diff --git a/config/hypr/scripts/Wlogout.sh b/config/hypr/scripts/Wlogout.sh index 3f83e51f..f552b83d 100755 --- a/config/hypr/scripts/Wlogout.sh +++ b/config/hypr/scripts/Wlogout.sh @@ -1,4 +1,57 @@ #!/bin/bash -# /* ----------- 💫 https://github.com/JaKooLit 💫 -------- */ # +# /* ---- 💫 https://github.com/JaKooLit 💫 ---- */ ## +# wlogout (Power, Screen Lock, Suspend, etc) -wlogout -p layer-shell -b 3 -c 2 \ No newline at end of file +# Set variables for parameters. First numbers corresponts to Monitor Resolution +# i.e 2160 means 2160p +A_2160=600 +B_2160=600 +A_1600=400 +B_1600=400 +A_1440=400 +B_1440=400 +A_1080=200 +B_1080=200 +A_720=50 +B_720=50 + +# Check if wlogout is already running +if pgrep -x "wlogout" > /dev/null; then + pkill -x "wlogout" + exit 0 +fi + +# Detect monitor resolution and scaling factor +resolution=$(hyprctl -j monitors | jq -r '.[] | select(.focused==true) | .height / .scale' | awk -F'.' '{print $1}') +hypr_scale=$(hyprctl -j monitors | jq -r '.[] | select(.focused==true) | .scale') + +# Set parameters based on screen resolution and scaling factor +if ((resolution >= 2160)); then + T_val=$(awk "BEGIN {printf \"%.0f\", $A_2160 * 2160 * $hypr_scale / $resolution}") + B_val=$(awk "BEGIN {printf \"%.0f\", $B_2160 * 2160 * $hypr_scale / $resolution}") + echo "Setting parameters for resolution >= 4k" + wlogout --protocol layer-shell -b 6 -T $T_val -B $B_val & +elif ((resolution >= 1600 && resolution < 2160)); then + T_val=$(awk "BEGIN {printf \"%.0f\", $A_1600 * 1600 * $hypr_scale / $resolution}") + B_val=$(awk "BEGIN {printf \"%.0f\", $B_1600 * 1600 * $hypr_scale / $resolution}") + echo "Setting parameters for resolution >= 2.5k and < 4k" + wlogout --protocol layer-shell -b 6 -T $T_val -B $B_val & +elif ((resolution >= 1440 && resolution < 1600)); then + T_val=$(awk "BEGIN {printf \"%.0f\", $A_1440 * 1440 * $hypr_scale / $resolution}") + B_val=$(awk "BEGIN {printf \"%.0f\", $B_1440 * 1440 * $hypr_scale / $resolution}") + echo "Setting parameters for resolution >= 2k and < 2.5k" + wlogout --protocol layer-shell -b 6 -T $T_val -B $B_val & +elif ((resolution >= 1080 && resolution < 1440)); then + T_val=$(awk "BEGIN {printf \"%.0f\", $A_1080 * 1080 * $hypr_scale / $resolution}") + B_val=$(awk "BEGIN {printf \"%.0f\", $B_1080 * 1080 * $hypr_scale / $resolution}") + echo "Setting parameters for resolution >= 1080p and < 2k" + wlogout --protocol layer-shell -b 6 -T $T_val -B $B_val & +elif ((resolution >= 720 && resolution < 1080)); then + T_val=$(awk "BEGIN {printf \"%.0f\", $A_720 * 720 * $hypr_scale / $resolution}") + B_val=$(awk "BEGIN {printf \"%.0f\", $B_720 * 720 * $hypr_scale / $resolution}") + echo "Setting parameters for resolution >= 720p and < 1080p" + wlogout --protocol layer-shell -b 3 -T $T_val -B $B_val & +else + echo "Setting default parameters" + wlogout & +fi diff --git a/config/wlogout/style.css b/config/wlogout/style.css index b8341e9a..ce227160 100644 --- a/config/wlogout/style.css +++ b/config/wlogout/style.css @@ -5,17 +5,15 @@ @import '../../.config/waybar/wallust/colors-waybar.css'; window { - font-family: "FantasqueSansM Nerd Font Mono Bold"; font-size: 24pt; color: @foreground; /* text */ - background-color: rgba(30, 30, 46, 0.6); + background-color: rgba(30, 30, 46, 0.8); } button { - margin: 20px; background-repeat: no-repeat; background-position: center; - background-size: 30%; + background-size: 20%; background-color: rgba(200, 220, 255, 0); animation: gradient_f 10s ease-in infinite; transition: all 0.3s cubic-bezier(.55, 0.0, .28, 1.682), box-shadow 0.2s ease-in-out, background-color 0.2s ease-in-out; @@ -24,19 +22,17 @@ button { } button:focus { - background-size: 40%; + background-size: 50%; border: 0px; - border-radius: 80px; } button:hover { background-color: transparent; - color: @color11; - background-size: 40%; - margin: -20px; + color: @color13; + background-size: 50%; + margin: 30px; border-radius: 80px; - /*box-shadow: 0 0 30px @color7;*/ } -- cgit v1.2.3 From 9007dd32c96421e0700c70a29b870957d6fe1a9f Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Fri, 28 Feb 2025 00:38:32 +0900 Subject: welp --- config/hypr/wallpaper_effects/.wallpaper_current | Bin 1031389 -> 2914074 bytes config/hypr/wallpaper_effects/.wallpaper_modified | Bin 442928 -> 1249466 bytes wallpapers/Balcony-ja.png | Bin 0 -> 2914074 bytes 3 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 wallpapers/Balcony-ja.png diff --git a/config/hypr/wallpaper_effects/.wallpaper_current b/config/hypr/wallpaper_effects/.wallpaper_current index c42ae068..9b4ff807 100644 Binary files a/config/hypr/wallpaper_effects/.wallpaper_current and b/config/hypr/wallpaper_effects/.wallpaper_current differ diff --git a/config/hypr/wallpaper_effects/.wallpaper_modified b/config/hypr/wallpaper_effects/.wallpaper_modified index 825086e1..795cdefe 100644 Binary files a/config/hypr/wallpaper_effects/.wallpaper_modified and b/config/hypr/wallpaper_effects/.wallpaper_modified differ diff --git a/wallpapers/Balcony-ja.png b/wallpapers/Balcony-ja.png new file mode 100644 index 00000000..9b4ff807 Binary files /dev/null and b/wallpapers/Balcony-ja.png differ -- cgit v1.2.3 From de91b9aadfee10c15aaf20b59d409aa1d395133c Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Fri, 28 Feb 2025 01:26:01 +0900 Subject: added accel_profile --- config/hypr/UserConfigs/UserSettings.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/config/hypr/UserConfigs/UserSettings.conf b/config/hypr/UserConfigs/UserSettings.conf index d488751c..9b526f2d 100644 --- a/config/hypr/UserConfigs/UserSettings.conf +++ b/config/hypr/UserConfigs/UserSettings.conf @@ -35,6 +35,7 @@ input { repeat_delay = 300 sensitivity = 0 #mouse sensitivity + accel_profile = # flat or adaptive or blank or EMPTY means libinput’s default mode numlock_by_default = true left_handed = false follow_mouse = true -- cgit v1.2.3 From 779c34304ab43e6cd07c256897908335d7997da3 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Fri, 28 Feb 2025 12:28:45 +0900 Subject: adjusted wallpaper menu scripts to apply some limits --- config/hypr/UserScripts/WallpaperSelect.sh | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/config/hypr/UserScripts/WallpaperSelect.sh b/config/hypr/UserScripts/WallpaperSelect.sh index ecb44c45..88b06dd6 100755 --- a/config/hypr/UserScripts/WallpaperSelect.sh +++ b/config/hypr/UserScripts/WallpaperSelect.sh @@ -8,8 +8,6 @@ wallDIR="$HOME/Pictures/wallpapers" SCRIPTSDIR="$HOME/.config/hypr/scripts" wallpaper_current="$HOME/.config/hypr/wallpaper_effects/.wallpaper_current" -rofi_override="element-icon{size:${icon_size}px;}" - # Directory for swaync iDIR="$HOME/.config/swaync/images" iDIRi="$HOME/.config/swaync/icons" @@ -18,13 +16,18 @@ iDIRi="$HOME/.config/swaync/icons" rofi_theme="$HOME/.config/rofi/config-wallpaper.rasi" focused_monitor=$(hyprctl monitors -j | jq -r '.[] | select(.focused) | .name') -# Get monitor width and DPI -monitor_width=$(hyprctl monitors -j | jq -r --arg mon "$focused_monitor" '.[] | select(.name == $mon) | .width') +# Monitor details scale_factor=$(hyprctl monitors -j | jq -r --arg mon "$focused_monitor" '.[] | select(.name == $mon) | .scale') +monitor_height=$(hyprctl monitors -j | jq -r --arg mon "$focused_monitor" '.[] | select(.name == $mon) | .height') + +icon_size=$(echo "scale=1; ($monitor_height * 3) / ($scale_factor * 150)" | bc) + +# Apply limit +adjusted_icon_size=$(echo "$icon_size" | awk '{if ($1 < 15) $1 = 20; if ($1 > 25) $1 = 25; print $1}') -icon_size=$(echo "scale=1; ($monitor_width * 3) / ($scale_factor * 400)" | bc) +# Setting the rofi override with the adjusted icon size +rofi_override="element-icon{size:${adjusted_icon_size}%;}" -rofi_override="element-icon{size:${icon_size}%;}" # swww transition config FPS=60 -- cgit v1.2.3