From d404c8b6b94d973334a1136223fbf5c412083bdb Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Mon, 10 Feb 2025 01:16:17 +0900 Subject: Initial upload of various rofi themes --- config/hypr/scripts/KeyBinds.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'config/hypr/scripts/KeyBinds.sh') diff --git a/config/hypr/scripts/KeyBinds.sh b/config/hypr/scripts/KeyBinds.sh index 9e01a7c3..f80211f5 100755 --- a/config/hypr/scripts/KeyBinds.sh +++ b/config/hypr/scripts/KeyBinds.sh @@ -14,6 +14,7 @@ fi KEYBINDS_CONF="$HOME/.config/hypr/configs/Keybinds.conf" USER_KEYBINDS_CONF="$HOME/.config/hypr/UserConfigs/UserKeybinds.conf" LAPTOP_CONF="$HOME/.config/hypr/UserConfigs/Laptop.conf" +rofi_theme="~/.config/rofi/config-keybinds.rasi" # Combine the contents of the keybinds files and filter for keybinds KEYBINDS=$(cat "$KEYBINDS_CONF" "$USER_KEYBINDS_CONF" | grep -E '^(bind|bindl|binde|bindm)') @@ -31,4 +32,4 @@ if [[ -z "$KEYBINDS" ]]; then fi # Use rofi to display the keybinds -echo "$KEYBINDS" | rofi -dmenu -i -p "Keybinds" -config ~/.config/rofi/config-keybinds.rasi \ No newline at end of file +echo "$KEYBINDS" | rofi -dmenu -i -config $rofi_theme \ No newline at end of file -- cgit v1.2.3 From a4c48b0ea0b2b1d474d503fb8d924d190762e999 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Thu, 13 Feb 2025 12:56:57 +0900 Subject: Improvements on the rofi. Utilized message function for additional informations when script is used in conjunction with rofi --- assets/rofi/themes/KooL_LonerOrZ.rasi | 12 ++++ assets/rofi/themes/KooL_style-1.rasi | 7 +- assets/rofi/themes/KooL_style-10-Fancy.rasi | 12 +++- .../rofi/themes/KooL_style-11-Win11-list-dark.rasi | 18 ++++-- .../themes/KooL_style-11-Win11-list-light.rasi | 17 +++-- assets/rofi/themes/KooL_style-2-Dark.rasi | 9 +-- assets/rofi/themes/KooL_style-2-Light.rasi | 10 ++- assets/rofi/themes/KooL_style-3-FullScreen-v1.rasi | 5 +- assets/rofi/themes/KooL_style-3-Fullscreen-v2.rasi | 11 ++-- assets/rofi/themes/KooL_style-4.rasi | 2 +- assets/rofi/themes/KooL_style-5.rasi | 6 +- assets/rofi/themes/KooL_style-6.rasi | 5 +- assets/rofi/themes/KooL_style-7.rasi | 6 +- assets/rofi/themes/KooL_style-8.rasi | 8 +-- assets/rofi/themes/KooL_style-9.rasi | 4 +- config/hypr/scripts/ClipManager.sh | 5 +- config/hypr/scripts/KeyBinds.sh | 9 +-- config/hypr/scripts/KeyHints.sh | 74 +++++++++++----------- config/hypr/scripts/RofiSearch.sh | 4 +- config/rofi/config-calc.rasi | 5 -- config/rofi/config-clipboard.rasi | 4 +- config/rofi/config-keybinds.rasi | 4 +- config/rofi/config-search.rasi | 5 +- 23 files changed, 137 insertions(+), 105 deletions(-) (limited to 'config/hypr/scripts/KeyBinds.sh') diff --git a/assets/rofi/themes/KooL_LonerOrZ.rasi b/assets/rofi/themes/KooL_LonerOrZ.rasi index d6a947ba..2803b693 100644 --- a/assets/rofi/themes/KooL_LonerOrZ.rasi +++ b/assets/rofi/themes/KooL_LonerOrZ.rasi @@ -166,3 +166,15 @@ element selected.active { background-color: @BGA; color: @FG; } + +/*****----- Message -----*****/ +error-message { + padding: 20px; +} +textbox { + padding: 10px; + background-color: @BG; + text-color: @FG; + vertical-align: 0.5; + horizontal-align: 0.5; +} diff --git a/assets/rofi/themes/KooL_style-1.rasi b/assets/rofi/themes/KooL_style-1.rasi index b8f58fff..9ac62fd7 100644 --- a/assets/rofi/themes/KooL_style-1.rasi +++ b/assets/rofi/themes/KooL_style-1.rasi @@ -84,7 +84,7 @@ entry { width: 20%; padding: 10px; border-radius: 12px; - background-color: @color11; + background-color: @active; text-color: @text-selected; cursor: text; placeholder: " 🖥️ Search "; @@ -230,12 +230,13 @@ message { border: 0px; } textbox { + margin: 10px; padding: 12px; border-radius: 10px; - background-color: @background; + background-color: @active; text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } error-message { padding: 12px; diff --git a/assets/rofi/themes/KooL_style-10-Fancy.rasi b/assets/rofi/themes/KooL_style-10-Fancy.rasi index 376cd3da..f5dc79e4 100644 --- a/assets/rofi/themes/KooL_style-10-Fancy.rasi +++ b/assets/rofi/themes/KooL_style-10-Fancy.rasi @@ -282,12 +282,18 @@ entry { } +/*****----- Message -----*****/ error-message { - background-color: darkred/10%; - border-color: darkred; + background-color: darkred/20%; border-radius: 10px; border: 2px; - padding: 0.5em; } +textbox { + padding: 5px; + background-color: darkred/10%; + vertical-align: 0.5; + horizontal-align: 0.5; +} + diff --git a/assets/rofi/themes/KooL_style-11-Win11-list-dark.rasi b/assets/rofi/themes/KooL_style-11-Win11-list-dark.rasi index d8958455..9dede9f8 100644 --- a/assets/rofi/themes/KooL_style-11-Win11-list-dark.rasi +++ b/assets/rofi/themes/KooL_style-11-Win11-list-dark.rasi @@ -81,11 +81,6 @@ entry { text-color : @fg1; } -textbox { - padding : 4px 8px; - background-color : @bg2; -} - listview { columns : 2; spacing : 8px; @@ -130,3 +125,16 @@ element-icon { element-text { text-color: inherit; } + +/*****----- Message -----*****/ +error-message { + padding: 20px; +} + +textbox { + padding : 10px; + background-color : @bg0; + text-color : @fg0; + vertical-align : 0.5; + horizontal-align : 0.5; +} diff --git a/assets/rofi/themes/KooL_style-11-Win11-list-light.rasi b/assets/rofi/themes/KooL_style-11-Win11-list-light.rasi index 8e2584b5..0e2600f1 100644 --- a/assets/rofi/themes/KooL_style-11-Win11-list-light.rasi +++ b/assets/rofi/themes/KooL_style-11-Win11-list-light.rasi @@ -81,10 +81,6 @@ entry { placeholder-color : @fg1; } -textbox { - padding : 4px 8px; - background-color : @bg2; -} listview { columns : 2; @@ -130,3 +126,16 @@ element-icon { element-text { text-color: inherit; } + +/*****----- Message -----*****/ +error-message { + padding: 20px; +} + +textbox { + padding : 10px; + background-color : @bg0; + text-color : @fg0; + vertical-align : 0.5; + horizontal-align : 0.5; +} diff --git a/assets/rofi/themes/KooL_style-2-Dark.rasi b/assets/rofi/themes/KooL_style-2-Dark.rasi index 036b7fae..cbacce1c 100644 --- a/assets/rofi/themes/KooL_style-2-Dark.rasi +++ b/assets/rofi/themes/KooL_style-2-Dark.rasi @@ -163,14 +163,11 @@ button selected { /*****----- Message -----*****/ error-message { padding: 20px; - background-color: transparent; - text-color: white; } textbox { - padding: 20px; - border-radius: 12px; - background-color: black/30%; + padding: 10px; + background-color: black/75%; text-color: white; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } diff --git a/assets/rofi/themes/KooL_style-2-Light.rasi b/assets/rofi/themes/KooL_style-2-Light.rasi index 9a8677ab..c2fc812f 100644 --- a/assets/rofi/themes/KooL_style-2-Light.rasi +++ b/assets/rofi/themes/KooL_style-2-Light.rasi @@ -164,14 +164,12 @@ button selected { /*****----- Message -----*****/ error-message { padding: 20px; - background-color: transparent; - text-color: black; } textbox { - padding: 20px; - border-radius: 12px; - background-color: white/30%; + padding: 10px; + background-color: gray/25%; text-color: black; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } + diff --git a/assets/rofi/themes/KooL_style-3-FullScreen-v1.rasi b/assets/rofi/themes/KooL_style-3-FullScreen-v1.rasi index 61a65ae8..a98a6fa8 100644 --- a/assets/rofi/themes/KooL_style-3-FullScreen-v1.rasi +++ b/assets/rofi/themes/KooL_style-3-FullScreen-v1.rasi @@ -240,12 +240,13 @@ message { border: 0px; } textbox { + margin: 10px; padding: 12px; border-radius: 10px; - background-color: @background-alt; + background-color: @selected; text-color: @background; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } error-message { padding: 12px; diff --git a/assets/rofi/themes/KooL_style-3-Fullscreen-v2.rasi b/assets/rofi/themes/KooL_style-3-Fullscreen-v2.rasi index 428c54a7..55277f61 100644 --- a/assets/rofi/themes/KooL_style-3-Fullscreen-v2.rasi +++ b/assets/rofi/themes/KooL_style-3-Fullscreen-v2.rasi @@ -197,17 +197,16 @@ element-text { /*****----- Message -----*****/ error-message { - padding: 100px; - border: 0px solid; - border-radius: 0px; + padding: 0px; border-color: @selected; - background-color: black / 10%; + background-color: transparent; text-color: @foreground; } textbox { - background-color: transparent; + padding: 20px; + background-color: black/10%; text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; highlight: none; } diff --git a/assets/rofi/themes/KooL_style-4.rasi b/assets/rofi/themes/KooL_style-4.rasi index 519f10f7..7eb03c45 100644 --- a/assets/rofi/themes/KooL_style-4.rasi +++ b/assets/rofi/themes/KooL_style-4.rasi @@ -312,7 +312,7 @@ textbox { background-color: @alternate-background; text-color: @foreground-color; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; highlight: none; placeholder-color: @foreground-color; blink: true; diff --git a/assets/rofi/themes/KooL_style-5.rasi b/assets/rofi/themes/KooL_style-5.rasi index cd9a5ce2..3d1f9220 100644 --- a/assets/rofi/themes/KooL_style-5.rasi +++ b/assets/rofi/themes/KooL_style-5.rasi @@ -165,7 +165,7 @@ listview { reverse: false; fixed-height: true; fixed-columns: false; - background-color: transparent; + background-color: @background; border-radius: 12px; border: 0px; } @@ -250,9 +250,9 @@ textbox { padding: 12px; border-radius: 10px; background-color: @background-alt; - text-color: @background; + text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } error-message { padding: 12px; diff --git a/assets/rofi/themes/KooL_style-6.rasi b/assets/rofi/themes/KooL_style-6.rasi index f5e7de43..bdc1b12d 100644 --- a/assets/rofi/themes/KooL_style-6.rasi +++ b/assets/rofi/themes/KooL_style-6.rasi @@ -216,12 +216,13 @@ message { border: 0px; } textbox { + margin: 10px; padding: 12px; border-radius: 10px; - background-color: @background; + background-color: @active; text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } error-message { padding: 12px; diff --git a/assets/rofi/themes/KooL_style-7.rasi b/assets/rofi/themes/KooL_style-7.rasi index 6d8c0201..c5bec637 100644 --- a/assets/rofi/themes/KooL_style-7.rasi +++ b/assets/rofi/themes/KooL_style-7.rasi @@ -186,9 +186,11 @@ error-message { text-color: @foreground; } textbox { - background-color: @background; + padding: 10px; + border-radius: 20px; + background-color: @color11; text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; highlight: none; } diff --git a/assets/rofi/themes/KooL_style-8.rasi b/assets/rofi/themes/KooL_style-8.rasi index ce262ad4..7a54dff5 100644 --- a/assets/rofi/themes/KooL_style-8.rasi +++ b/assets/rofi/themes/KooL_style-8.rasi @@ -228,15 +228,15 @@ message { } textbox { padding: 12px; - border-radius: 10px; - background-color: @background; + border-radius: 0px; + background-color: @color11; text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } error-message { padding: 12px; - border-radius: 20px; + border-radius: 0px; background-color: @background; text-color: @foreground; } diff --git a/assets/rofi/themes/KooL_style-9.rasi b/assets/rofi/themes/KooL_style-9.rasi index 5ac5c0f9..a03f877f 100644 --- a/assets/rofi/themes/KooL_style-9.rasi +++ b/assets/rofi/themes/KooL_style-9.rasi @@ -199,10 +199,10 @@ message { textbox { padding: 12px; border-radius: 10px; - background-color: @background; + background-color: @BDR; text-color: @foreground; vertical-align: 0.5; - horizontal-align: 0.0; + horizontal-align: 0.5; } error-message { padding: 12px; diff --git a/config/hypr/scripts/ClipManager.sh b/config/hypr/scripts/ClipManager.sh index 642adb82..1f82c616 100755 --- a/config/hypr/scripts/ClipManager.sh +++ b/config/hypr/scripts/ClipManager.sh @@ -4,7 +4,7 @@ # Variables rofi_theme="~/.config/rofi/config-clipboard.rasi" - +msg='👀 **note** CTRL DEL = cliphist del (entry) or ALT DEL - cliphist wipe (all)' # Actions: # CTRL Del to delete an entry # ALT Del to wipe clipboard contents @@ -19,7 +19,8 @@ while true; do rofi -i -dmenu \ -kb-custom-1 "Control-Delete" \ -kb-custom-2 "Alt-Delete" \ - -config $rofi_theme < <(cliphist list) + -config $rofi_theme < <(cliphist list) \ + -mesg "$msg" ) case "$?" in diff --git a/config/hypr/scripts/KeyBinds.sh b/config/hypr/scripts/KeyBinds.sh index f80211f5..ffa53281 100755 --- a/config/hypr/scripts/KeyBinds.sh +++ b/config/hypr/scripts/KeyBinds.sh @@ -14,7 +14,8 @@ fi KEYBINDS_CONF="$HOME/.config/hypr/configs/Keybinds.conf" USER_KEYBINDS_CONF="$HOME/.config/hypr/UserConfigs/UserKeybinds.conf" LAPTOP_CONF="$HOME/.config/hypr/UserConfigs/Laptop.conf" -rofi_theme="~/.config/rofi/config-keybinds.rasi" +rofi_theme="$HOME/.config/rofi/config-keybinds.rasi" +msg='☣️ NOTE ☣️: Clicking with Mouse or Pressing ENTER will have NO function' # Combine the contents of the keybinds files and filter for keybinds KEYBINDS=$(cat "$KEYBINDS_CONF" "$USER_KEYBINDS_CONF" | grep -E '^(bind|bindl|binde|bindm)') @@ -25,11 +26,11 @@ if [[ -f "$LAPTOP_CONF" ]]; then KEYBINDS+=$'\n'"$LAPTOP_BINDS" fi -# check for any keybinds to display +# Check for any keybinds to display if [[ -z "$KEYBINDS" ]]; then echo "No keybinds found." exit 1 fi -# Use rofi to display the keybinds -echo "$KEYBINDS" | rofi -dmenu -i -config $rofi_theme \ No newline at end of file +# Ensure the message is being passed correctly +echo "$KEYBINDS" | rofi -dmenu -i -config "$rofi_theme" -mesg "$msg" diff --git a/config/hypr/scripts/KeyHints.sh b/config/hypr/scripts/KeyHints.sh index d7c6a00d..d69f5de8 100755 --- a/config/hypr/scripts/KeyHints.sh +++ b/config/hypr/scripts/KeyHints.sh @@ -23,48 +23,48 @@ GDK_BACKEND=$BACKEND yad \ --column=Description: \ --column=Command: \ --timeout-indicator=bottom \ -"ESC" "close this app" "" " = " "SUPER KEY (Windows Key Button)" "(SUPER KEY)" \ -" SHIFT K" "Searchable Keybinds" "(Search all Keybinds via rofi)" \ +"ESC" "close this app" "" " = " "SUPER KEY (Windows Key Button)" "(SUPER KEY)" \ +" SHIFT K" "Searchable Keybinds" "(Search all Keybinds via rofi)" \ +" SHIFT E" "View or EDIT Keybinds, Settings, Monitor" "" \ "" "" "" \ -" SHIFT E" "View or EDIT Keybinds, Settings, Monitor" "" \ -" enter" "Terminal" "(kitty)" \ -" SHIFT enter" "DropDown Terminal" "(Not available in Debian and Ubuntu)" \ -" B" "Launch Browser" "(Default browser)" \ -" A" "Desktop Overview" "(AGS - if opted to install)" \ -" D" "Application Launcher" "(rofi-wayland)" \ -" E" "Open File Manager" "(Thunar)" \ -" S" "Google Search using rofi" "(rofi)" \ -" Q" "close active window" "(not kill)" \ -" Shift Q " "kills an active window" "(kill)" \ -" Z" "Desktop Zoom" "(Not available in Debian and Ubuntu)" \ -" Alt V" "Clipboard Manager" "(cliphist)" \ -" W" "Choose wallpaper" "(Wallpaper Menu)" \ -" Shift W" "Choose wallpaper effects" "(imagemagick + swww)" \ +" enter" "Terminal" "(kitty)" \ +" SHIFT enter" "DropDown Terminal" "(Not available in Debian and Ubuntu)" \ +" B" "Launch Browser" "(Default browser)" \ +" A" "Desktop Overview" "(AGS - if opted to install)" \ +" D" "Application Launcher" "(rofi-wayland)" \ +" E" "Open File Manager" "(Thunar)" \ +" S" "Google Search using rofi" "(rofi)" \ +" Q" "close active window" "(not kill)" \ +" Shift Q " "kills an active window" "(kill)" \ +" Z" "Desktop Zoom" "(Not available in Debian and Ubuntu)" \ +" Alt V" "Clipboard Manager" "(cliphist)" \ +" W" "Choose wallpaper" "(Wallpaper Menu)" \ +" Shift W" "Choose wallpaper effects" "(imagemagick + swww)" \ "CTRL ALT W" "Random wallpaper" "(via swww)" \ -" CTRL ALT B" "Hide/UnHide Waybar" "waybar" \ -" CTRL B" "Choose waybar styles" "(waybar styles)" \ -" ALT B" "Choose waybar layout" "(waybar layout)" \ -" ALT R" "Reload Waybar swaync Rofi" "CHECK NOTIFICATION FIRST!!!" \ -" SHIFT N" "Launch Notification Panel" "swaync Notification Center" \ -" Print" "screenshot" "(grim)" \ -" Shift Print" "screenshot region" "(grim + slurp)" \ -" Shift S" "screenshot region" "(swappy)" \ -" CTRL Print" "screenshot timer 5 secs " "(grim)" \ -" CTRL SHIFT Print" "screenshot timer 10 secs " "(grim)" \ +" CTRL ALT B" "Hide/UnHide Waybar" "waybar" \ +" CTRL B" "Choose waybar styles" "(waybar styles)" \ +" ALT B" "Choose waybar layout" "(waybar layout)" \ +" ALT R" "Reload Waybar swaync Rofi" "CHECK NOTIFICATION FIRST!!!" \ +" SHIFT N" "Launch Notification Panel" "swaync Notification Center" \ +" Print" "screenshot" "(grim)" \ +" Shift Print" "screenshot region" "(grim + slurp)" \ +" Shift S" "screenshot region" "(swappy)" \ +" CTRL Print" "screenshot timer 5 secs " "(grim)" \ +" CTRL SHIFT Print" "screenshot timer 10 secs " "(grim)" \ "ALT Print" "Screenshot active window" "active window only" \ "CTRL ALT P" "power-menu" "(wlogout)" \ "CTRL ALT L" "screen lock" "(hyprlock)" \ "CTRL ALT Del" "Hyprland Exit" "(NOTE: Hyprland Will exit immediately)" \ -" SHIFT F" "Fullscreen" "Toggles to full screen" \ -" CTL F" "Fake Fullscreen" "Toggles to fake full screen" \ -" ALT L" "Toggle Dwindle | Master Layout" "Hyprland Layout" \ -" SPACEBAR" "Toggle float" "single window" \ -" ALT SPACEBAR" "Toggle all windows to float" "all windows" \ -" ALT O" "Toggle Blur" "normal or less blur" \ -" Shift A" "Animations Menu" "Choose Animations via rofi" \ -" SHIFT G" "Gamemode! All animations OFF or ON" "toggle" \ -" ALT E" "Rofi Emoticons" "Emoticon" \ -" ALT V" "Clipboard Manager" "cliphist" \ -" H" "Launch this QUICK CHEAT" "" \ +" SHIFT F" "Fullscreen" "Toggles to full screen" \ +" CTL F" "Fake Fullscreen" "Toggles to fake full screen" \ +" ALT L" "Toggle Dwindle | Master Layout" "Hyprland Layout" \ +" SPACEBAR" "Toggle float" "single window" \ +" ALT SPACEBAR" "Toggle all windows to float" "all windows" \ +" ALT O" "Toggle Blur" "normal or less blur" \ +" Shift A" "Animations Menu" "Choose Animations via rofi" \ +" SHIFT G" "Gamemode! All animations OFF or ON" "toggle" \ +" ALT E" "Rofi Emoticons" "Emoticon" \ +" ALT V" "Clipboard Manager" "cliphist" \ +" H" "Launch this QUICK CHEAT" "" \ "" "" "" \ "More tips:" "https://github.com/JaKooLit/Hyprland-Dots/wiki" ""\ \ No newline at end of file diff --git a/config/hypr/scripts/RofiSearch.sh b/config/hypr/scripts/RofiSearch.sh index d9576a1a..e256253a 100755 --- a/config/hypr/scripts/RofiSearch.sh +++ b/config/hypr/scripts/RofiSearch.sh @@ -5,7 +5,7 @@ # Opens rofi in dmenu mod and waits for input. Then pushes the input to the query of the URL. rofi_theme="$HOME/.config/rofi/config-search.rasi" - +msg='‼️ **note** ‼️ search via default web browser' # Kill Rofi if already running before execution if pgrep -x "rofi" >/dev/null; then pkill rofi @@ -15,4 +15,4 @@ fi # Open rofi with a dmenu and pass the selected item to xdg-open for Google search #echo "" | rofi -dmenu -config "$rofi_config" | xargs -I{} xdg-open "https://www.google.com/search?q={}" -echo "" | rofi -dmenu -config $rofi_theme | xargs -I{} xdg-open "https://www.google.com/search?q={}" +echo "" | rofi -dmenu -config $rofi_theme -mesg "$msg" | xargs -I{} xdg-open "https://www.google.com/search?q={}" diff --git a/config/rofi/config-calc.rasi b/config/rofi/config-calc.rasi index 60169c31..1dfd1887 100644 --- a/config/rofi/config-calc.rasi +++ b/config/rofi/config-calc.rasi @@ -17,9 +17,4 @@ entry { placeholder: " 🧮 Calculate"; } -textbox { - padding: 12px; - border-radius: 10px; -} - listview {enable: false;} \ No newline at end of file diff --git a/config/rofi/config-clipboard.rasi b/config/rofi/config-clipboard.rasi index 648a96af..01596ee0 100644 --- a/config/rofi/config-clipboard.rasi +++ b/config/rofi/config-clipboard.rasi @@ -11,13 +11,13 @@ window { /* ---- Mainbox ---- */ mainbox { children: - [ "inputbar", "listview"]; + [ "inputbar", "message", "listview"]; } /* ---- Entry ---- */ entry { width: 42%; - placeholder: " 📋 Search Clipboard **note** 👀 CTRL Del - Cliphist del or Alt Del - cliphist wipe"; + placeholder: " 📋 Search Clipboard "; } /* ---- Listview ---- */ diff --git a/config/rofi/config-keybinds.rasi b/config/rofi/config-keybinds.rasi index 6c8e2d5a..ccc8b4d7 100644 --- a/config/rofi/config-keybinds.rasi +++ b/config/rofi/config-keybinds.rasi @@ -7,13 +7,13 @@ /* ---- Mainbox ---- */ mainbox { children: - [ "inputbar", "listview"]; + [ "inputbar", "message", "listview"]; } /* ---- Entry ---- */ entry { expand: true; - placeholder: " 🧮 Search Keybinds ☣️ NOTE ☣️: Clicking with Mouse or Pressing ENTER will have NO function"; + placeholder: " 🧮 Search Keybinds"; } /* ---- Listview ---- */ diff --git a/config/rofi/config-search.rasi b/config/rofi/config-search.rasi index a2ff66ee..733d9b9a 100644 --- a/config/rofi/config-search.rasi +++ b/config/rofi/config-search.rasi @@ -9,14 +9,15 @@ window { height: inherit; y-offset: 10px; location: north; - children: [ "entry" ]; + children: [ "entry", "message" ]; border: 2px; border-color: white/25%; } /* ---- Entry ---- */ entry { - placeholder: " 🔎 Google Search via web browser"; + placeholder: " 🔎 Google Search"; + horizontal-align: 0.5; padding: 15px; border: 0px; border-radius: 12px; -- cgit v1.2.3 From 02c9626c1da104fbcdf32b4b11896e3b9f650531 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Fri, 14 Feb 2025 12:18:52 +0900 Subject: updated keybinds --- config/hypr/scripts/KeyBinds.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'config/hypr/scripts/KeyBinds.sh') diff --git a/config/hypr/scripts/KeyBinds.sh b/config/hypr/scripts/KeyBinds.sh index ffa53281..639dd3a1 100755 --- a/config/hypr/scripts/KeyBinds.sh +++ b/config/hypr/scripts/KeyBinds.sh @@ -13,16 +13,16 @@ fi # Define the config files KEYBINDS_CONF="$HOME/.config/hypr/configs/Keybinds.conf" USER_KEYBINDS_CONF="$HOME/.config/hypr/UserConfigs/UserKeybinds.conf" -LAPTOP_CONF="$HOME/.config/hypr/UserConfigs/Laptop.conf" +LAPTOP_CONF="$HOME/.config/hypr/UserConfigs/Laptops.conf" rofi_theme="$HOME/.config/rofi/config-keybinds.rasi" msg='☣️ NOTE ☣️: Clicking with Mouse or Pressing ENTER will have NO function' # Combine the contents of the keybinds files and filter for keybinds -KEYBINDS=$(cat "$KEYBINDS_CONF" "$USER_KEYBINDS_CONF" | grep -E '^(bind|bindl|binde|bindm)') +KEYBINDS=$(cat "$KEYBINDS_CONF" "$USER_KEYBINDS_CONF" | grep -E '^bind') # Check if Laptop.conf exists and add its keybinds if present if [[ -f "$LAPTOP_CONF" ]]; then - LAPTOP_BINDS=$(grep -E '^(bind|bindl|binde|bindm)' "$LAPTOP_CONF") + LAPTOP_BINDS=$(grep -E '^bind' "$LAPTOP_CONF") KEYBINDS+=$'\n'"$LAPTOP_BINDS" fi @@ -32,5 +32,5 @@ if [[ -z "$KEYBINDS" ]]; then exit 1 fi -# Ensure the message is being passed correctly +# Use rofi to display the keybinds echo "$KEYBINDS" | rofi -dmenu -i -config "$rofi_theme" -mesg "$msg" -- cgit v1.2.3 From b478eef5f63d237eda06256bd4508c545bc6bcbe Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Sat, 15 Feb 2025 12:45:34 +0900 Subject: updated keybinds search & rofi theme selector scripts --- config/hypr/scripts/KeyBinds.sh | 40 ++++++------ config/hypr/scripts/RofiThemeSelector-modified.sh | 75 ++++++++++++----------- config/hypr/scripts/RofiThemeSelector.sh | 4 +- 3 files changed, 63 insertions(+), 56 deletions(-) (limited to 'config/hypr/scripts/KeyBinds.sh') diff --git a/config/hypr/scripts/KeyBinds.sh b/config/hypr/scripts/KeyBinds.sh index 639dd3a1..324a9d00 100755 --- a/config/hypr/scripts/KeyBinds.sh +++ b/config/hypr/scripts/KeyBinds.sh @@ -1,36 +1,40 @@ #!/bin/bash # /* ---- 💫 https://github.com/JaKooLit 💫 ---- */ ## -# Searchable enabled keybinds using rofi +# searchable enabled keybinds using rofi -# Kill yad to not interfere with this binds +# kill yad to not interfere with this binds pkill yad || true -# Check if rofi is already running +# check if rofi is already running if pidof rofi > /dev/null; then pkill rofi fi -# Define the config files -KEYBINDS_CONF="$HOME/.config/hypr/configs/Keybinds.conf" -USER_KEYBINDS_CONF="$HOME/.config/hypr/UserConfigs/UserKeybinds.conf" -LAPTOP_CONF="$HOME/.config/hypr/UserConfigs/Laptops.conf" +# define the config files +keybinds_conf="$HOME/.config/hypr/configs/Keybinds.conf" +user_keybinds_conf="$HOME/.config/hypr/UserConfigs/UserKeybinds.conf" +laptop_conf="$HOME/.config/hypr/UserConfigs/Laptops.conf" rofi_theme="$HOME/.config/rofi/config-keybinds.rasi" msg='☣️ NOTE ☣️: Clicking with Mouse or Pressing ENTER will have NO function' -# Combine the contents of the keybinds files and filter for keybinds -KEYBINDS=$(cat "$KEYBINDS_CONF" "$USER_KEYBINDS_CONF" | grep -E '^bind') +# combine the contents of the keybinds files and filter for keybinds +keybinds=$(cat "$keybinds_conf" "$user_keybinds_conf" | grep -E '^bind') -# Check if Laptop.conf exists and add its keybinds if present -if [[ -f "$LAPTOP_CONF" ]]; then - LAPTOP_BINDS=$(grep -E '^bind' "$LAPTOP_CONF") - KEYBINDS+=$'\n'"$LAPTOP_BINDS" +# check if laptop.conf exists and add its keybinds if present +if [[ -f "$laptop_conf" ]]; then + laptop_binds=$(grep -E '^bind' "$laptop_conf") + keybinds+=$'\n'"$laptop_binds" fi -# Check for any keybinds to display -if [[ -z "$KEYBINDS" ]]; then - echo "No keybinds found." +# check for any keybinds to display +if [[ -z "$keybinds" ]]; then + echo "no keybinds found." exit 1 fi -# Use rofi to display the keybinds -echo "$KEYBINDS" | rofi -dmenu -i -config "$rofi_theme" -mesg "$msg" +# replace $mainmod with super in the displayed keybinds for rofi +display_keybinds=$(echo "$keybinds" | sed 's/\$mainMod/SUPER/g') + +# use rofi to display the keybinds with the modified content +echo "$display_keybinds" | rofi -dmenu -i -config "$rofi_theme" -mesg "$msg" +s \ No newline at end of file diff --git a/config/hypr/scripts/RofiThemeSelector-modified.sh b/config/hypr/scripts/RofiThemeSelector-modified.sh index e4d476c3..2af75a73 100755 --- a/config/hypr/scripts/RofiThemeSelector-modified.sh +++ b/config/hypr/scripts/RofiThemeSelector-modified.sh @@ -36,7 +36,7 @@ then fi TMP_CONFIG_FILE=$(${MKTEMP}).rasi -rofi_theme_dir="${HOME}/.local/share/rofi/themes" +#rofi_theme_dir="${HOME}/.local/share/rofi/themes" rofi_config_file="${XDG_CONFIG_HOME:-${HOME}/.config}/rofi/config.rasi" ## @@ -50,32 +50,25 @@ declare -a theme_names # Function that tries to find all installed rofi themes. # This fills in #themes array and formats a displayable string #theme_names ## -find_themes() -{ - DIRS="${HOME}/.local/share" - OLDIFS=${IFS} - IFS=: - # Add user dir. - DIRS+=":${XDG_CONFIG_HOME:-${HOME}/.config}" - for p in ${DIRS}; do - p=${p%/} - TD=${p}/rofi/themes - if [ -n "${p}" ] && [ -d "${TD}" ] - then - echo "Checking themes in: ${TD}" - for file in ${TD}/*.rasi - do - if [ -f "${file}" ] - then - themes+=("${file}") - FN=$(basename "${file}") - NAME=${FN%.*} # Extract the file name without extension - theme_names+=("${NAME}") # Only add the base file name +# Find themes in defined directories +find_themes() { + directories=("$HOME/.local/share/rofi/themes" "$HOME/.config/rofi/themes") + + for TD in "${directories[@]}"; do + if [ -d "$TD" ]; then + echo "Checking themes in: $TD" + for file in "$TD"/*.rasi; do + if [ -f "$file" ] && [ ! -L "$file" ]; then + themes+=("$file") + theme_names+=("$(basename "${file%.*}")") + else + echo "Skipping symlink: $file" fi - done + done + else + echo "Directory does not exist: $TD" fi done - IFS=${OLDIFS} } ## @@ -83,16 +76,27 @@ find_themes() ## add_theme_to_config() { local theme_name="$1" - local theme_path="$rofi_theme_dir/$theme_name" - - # if config in $HOME to write as $HOME - if [[ "$theme_path" == $HOME/* ]]; then - theme_path_with_tilde="~${theme_path#$HOME}" + local theme_path + + # Determine the correct path for the theme + if [[ -f "$HOME/.local/share/rofi/themes/$theme_name.rasi" ]]; then + theme_path="$HOME/.local/share/rofi/themes/$theme_name.rasi" + elif [[ -f "$HOME/.config/rofi/themes/$theme_name.rasi" ]]; then + theme_path="$HOME/.config/rofi/themes/$theme_name.rasi" else - theme_path_with_tilde="$theme_path" + echo "Theme not found: $theme_name" + return 1 fi - # If no @theme is in the file, add it + # Resolve symlinks if present + if [[ -L "$theme_path" ]]; then + theme_path=$(readlink -f "$theme_path") + fi + + # Convert path to use ~ for home directory + theme_path_with_tilde="~${theme_path#$HOME}" + + # Add or update @theme line in config if ! grep -q '^\s*@theme' "$rofi_config_file"; then echo -e "\n\n@theme \"$theme_path_with_tilde\"" >> "$rofi_config_file" echo "Added @theme \"$theme_path_with_tilde\" to $rofi_config_file" @@ -102,13 +106,12 @@ add_theme_to_config() { echo "Updated @theme line to $theme_path_with_tilde" fi - # Ensure no more than max # of lines with //@theme lines - max_line="9" + # Limit the number of @theme lines to a maximum of 9 + max_lines=9 total_lines=$(grep -c '^\s*//@theme' "$rofi_config_file") - if [ "$total_lines" -gt "$max_line" ]; then - excess=$((total_lines - max_line)) - # Remove the oldest or the very top //@theme lines + if [ "$total_lines" -gt "$max_lines" ]; then + excess=$((total_lines - max_lines)) for i in $(seq 1 "$excess"); do $SED -i '0,/^\s*\/\/@theme/ { /^\s*\/\/@theme/ {d; q; }}' "$rofi_config_file" done diff --git a/config/hypr/scripts/RofiThemeSelector.sh b/config/hypr/scripts/RofiThemeSelector.sh index cbce04b0..968d1f30 100755 --- a/config/hypr/scripts/RofiThemeSelector.sh +++ b/config/hypr/scripts/RofiThemeSelector.sh @@ -5,7 +5,7 @@ IFS=$'\n\t' # Define directories and variables -rofi_theme_dir="$HOME/.local/share/rofi/themes" +rofi_theme_dir="$HOME/.config/rofi/themes" rofi_config_file="$HOME/.config/rofi/config.rasi" SED=$(which sed) iDIR="$HOME/.config/swaync/images" @@ -25,7 +25,7 @@ menu() { add_theme_to_config() { local theme_name="$1" local theme_path="$rofi_theme_dir/$theme_name" - + # if config in $HOME to write as $HOME if [[ "$theme_path" == $HOME/* ]]; then theme_path_with_tilde="~${theme_path#$HOME}" -- cgit v1.2.3