From e251ac2fffbd4d7a1dcc256723841fd25c59b7f2 Mon Sep 17 00:00:00 2001 From: Nikolai Papin Date: Mon, 22 Sep 2025 17:48:56 +0300 Subject: [PATCH] feat: reserved screen space keybind and pinning windows for watching shows in the background; refactor: waybar adjustments; refactor: swaync idle inhibitor now handles idle state correctly; feat: rmpc config --- .gitignore | 1 + hypr/hyprland.conf | 13 +- hypr/hyprpaper.conf | 4 +- hypr/monitors.conf | 5 +- hypr/scripts/random_wallpaper.sh | 13 +- hypr/scripts/reserved_space.sh | 14 + hypr/workspaces.conf | 0 rmpc/config.ron | 138 ++++++++++ rmpc/themes/kolinux.ron | 182 +++++++++++++ swaync/config.json | 8 +- swaync/scripts/idle_inhibit_check.sh | 1 + swaync/scripts/idle_inhibit_toggle.sh | 10 + waybar/config.jsonc | 4 +- waybar/config2.jsonc | 237 ----------------- waybar/orig/config.jsonc | 201 --------------- waybar/orig/style.css | 327 ------------------------ waybar/origcolors.css | 351 -------------------------- waybar/style.css | 14 +- 18 files changed, 386 insertions(+), 1137 deletions(-) create mode 100755 hypr/scripts/reserved_space.sh create mode 100644 hypr/workspaces.conf create mode 100644 rmpc/config.ron create mode 100644 rmpc/themes/kolinux.ron create mode 100755 swaync/scripts/idle_inhibit_check.sh create mode 100755 swaync/scripts/idle_inhibit_toggle.sh delete mode 100644 waybar/config2.jsonc delete mode 100644 waybar/orig/config.jsonc delete mode 100644 waybar/orig/style.css delete mode 100644 waybar/origcolors.css diff --git a/.gitignore b/.gitignore index 35082d1..3113dc0 100644 --- a/.gitignore +++ b/.gitignore @@ -55,6 +55,7 @@ !picom/** !polybar/** !ranger/** +!rmpc/** !rofi/** !rofi-wayland/** !swaync/** diff --git a/hypr/hyprland.conf b/hypr/hyprland.conf index 233e32e..93c6573 100644 --- a/hypr/hyprland.conf +++ b/hypr/hyprland.conf @@ -3,8 +3,9 @@ ################ # See https://wiki.hyprland.org/Configuring/Monitors/ -# monitor=eDP-1, 1920x1080, 0x0, 1 -# monitor=HDMI-A-1, 1920x1080, -1920x-100, 1 +monitor=eDP-1, 1920x1080, 0x0, 1 +monitor=HDMI-A-1, 1920x1080, -1920x-100, 1 +# monitor=eDP-1,addreserved,0,0,0,625 ################### ### MY PROGRAMS ### @@ -35,6 +36,7 @@ exec-once = mullvad-vpn & exec-once = swaync exec-once = ~/.config/hypr/scripts/random_wallpaper.sh exec-once = ~/.config/hypr/scripts/autofreezer.sh +exec-once = ~/.config/bspwm/checkupdates.sh # exec-once = systemctl --user startexec-once=dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP hyprpaper.service exec-once = libinput-gestures @@ -323,7 +325,7 @@ binde = $mainMod SHIFT, W, forcekillactive, bind = $mainMod, S, togglefloating, bind = $mainMod, T, settiled, bind = $mainMod, F, fullscreen, -bind = $mainMod CTRL, P, pin, +bind = $mainMod CTRL, P, pin # Bring to top bind = $mainMod, Z, bringactivetotop @@ -481,6 +483,9 @@ bind = $mainMod CTRL, G, exec, ~/.config/hypr/scripts/grayscale-toggle.sh # Game mode bind = $mainMod SHIFT, G, exec, ~/.config/hypr/scripts/gamemode.sh +# Enable reserved space +bind = $mainMod, B, exec, ~/.config/hypr/scripts/reserved_space.sh + # Cycle cpu frequency mode bind = $mainMod CTRL, C, exec, ~/.config/hypr/scripts/cpufreq.sh @@ -592,4 +597,4 @@ debug { disable_logs = false } -source = ~/.config/hypr/monitors.conf +# source = ~/.config/hypr/monitors.conf diff --git a/hypr/hyprpaper.conf b/hypr/hyprpaper.conf index f39f533..390683a 100644 --- a/hypr/hyprpaper.conf +++ b/hypr/hyprpaper.conf @@ -1,4 +1,4 @@ -wallpaper = eDP-1,/home/greg/Pictures/Wallpapers/current/lemon_spray_black_166821_1920x1080.jpg -wallpaper = HDMI-A-1,/home/greg/Pictures/Wallpapers/current/lemon_spray_black_166821_1920x1080.jpg +wallpaper = eDP-1,/home/greg/Pictures/Wallpapers/ryabina.jpg +wallpaper = HDMI-A-1,/home/greg/Pictures/Wallpapers/ryabina.jpg ipc = on diff --git a/hypr/monitors.conf b/hypr/monitors.conf index 2a93391..9628e75 100644 --- a/hypr/monitors.conf +++ b/hypr/monitors.conf @@ -1,3 +1,4 @@ -# Generated by nwg-displays on 2025-09-17 at 19:51:26. Do not edit manually. +# Generated by nwg-displays on 2025-09-20 at 10:12:32. Do not edit manually. -monitor=eDP-1,1920x1080@60.01,0x0,1.0 +monitor=eDP-1,1920x1080@60.01,2560x0,1.0 +monitor=HDMI-A-1,3840x2160@30.0,0x0,1.5 diff --git a/hypr/scripts/random_wallpaper.sh b/hypr/scripts/random_wallpaper.sh index 2a22e73..bf69793 100755 --- a/hypr/scripts/random_wallpaper.sh +++ b/hypr/scripts/random_wallpaper.sh @@ -2,7 +2,7 @@ WALLPAPER_DIR="$HOME/Pictures/Wallpapers/current/" INTRO_DIR="$HOME/Pictures/Wallpapers/intro/" -DELAY=3m +DELAY=5m intro() { if [ -z "$(ls -A "$WALLPAPER_DIR")" ]; then @@ -39,7 +39,6 @@ random_wallpaper() { WALLPAPER=$(find "$WALLPAPER_DIR" -type l ! -name "$(basename "$CURRENT_WALL")" | shuf -n 1) # Apply the selected wallpaper - hyprctl hyprpaper unload all hyprctl hyprpaper reload $1,"$WALLPAPER" if [ $? -ne 0 ]; then @@ -51,10 +50,20 @@ random_wallpaper() { fi echo "Set random wallpaper to $WALLPAPER" + sleep 5 } loop() { while true; do + hyprctl hyprpaper listactive + if [ $? == 0 ]; then + break + fi + sleep 1 + done + while true; do + hyprctl hyprpaper unload all + # TODO: get monitors dynamically random_wallpaper "eDP-1" random_wallpaper "HDMI-A-1" sleep "$DELAY" diff --git a/hypr/scripts/reserved_space.sh b/hypr/scripts/reserved_space.sh new file mode 100755 index 0000000..9ebc094 --- /dev/null +++ b/hypr/scripts/reserved_space.sh @@ -0,0 +1,14 @@ +#!/usr/bin/env sh + +FILE="/tmp/reserved_space_enabled" + +if [ ! -e "$FILE" ]; then + touch "$FILE" + hyprctl --batch "\ + keyword monitor eDP-1,addreserved,0,0,0,625;" + exit +fi + +rm "$FILE" +hyprctl --batch "\ + keyword monitor eDP-1,addreserved,0,0,0,0;" diff --git a/hypr/workspaces.conf b/hypr/workspaces.conf new file mode 100644 index 0000000..e69de29 diff --git a/rmpc/config.ron b/rmpc/config.ron new file mode 100644 index 0000000..cd02669 --- /dev/null +++ b/rmpc/config.ron @@ -0,0 +1,138 @@ +#![enable(implicit_some)] +#![enable(unwrap_newtypes)] +#![enable(unwrap_variant_newtypes)] +( + address: "127.0.0.1:6600", + password: "kapuchinamusica", + theme: "kolinux", + cache_dir: None, + on_song_change: None, + volume_step: 5, + max_fps: 30, + scrolloff: 0, + wrap_navigation: false, + enable_mouse: true, + status_update_interval_ms: 1000, + select_current_song_on_change: false, + album_art: ( + method: Auto, + max_size_px: (width: 1200, height: 1200), + disabled_protocols: ["http://", "https://"], + vertical_align: Center, + horizontal_align: Center, + ), + keybinds: ( + global: { + ":": CommandMode, + ",": VolumeDown, + "s": Stop, + ".": VolumeUp, + "": NextTab, + "": PreviousTab, + "1": SwitchToTab("Queue"), + "2": SwitchToTab("Dirs"), + "3": SwitchToTab("Artists"), + "4": SwitchToTab("Albums"), + "5": SwitchToTab("Playlists"), + "q": Quit, + ">": NextTrack, + "p": TogglePause, + "<": PreviousTrack, + "f": SeekForward, + "z": ToggleRepeat, + "x": ToggleRandom, + "c": ToggleConsume, + "v": ToggleSingle, + "b": SeekBack, + "~": ShowHelp, + "I": ShowCurrentSongInfo, + "O": ShowOutputs, + "P": ShowDecoders, + }, + navigation: { + "k": Up, + "j": Down, + "h": Left, + "l": Right, + "": Up, + "": Down, + "": Left, + "": Right, + "": PaneUp, + "": PaneDown, + "": PaneLeft, + "": PaneRight, + "": UpHalf, + "N": PreviousResult, + "a": Add, + "A": AddAll, + "r": Rename, + "n": NextResult, + "g": Top, + "": Select, + "": InvertSelection, + "G": Bottom, + "": Confirm, + "i": FocusInput, + "J": MoveDown, + "": DownHalf, + "/": EnterSearch, + "": Close, + "": Close, + "K": MoveUp, + "D": Delete, + }, + queue: { + "D": DeleteAll, + "": Play, + "": Save, + "a": AddToPlaylist, + "d": Delete, + "i": ShowInfo, + "o": JumpToCurrent, + }, + ), + search: ( + case_sensitive: false, + mode: Contains, + tags: [ + (value: "any", label: "Any Tag"), + (value: "artist", label: "Artist"), + (value: "album", label: "Album"), + (value: "albumartist", label: "Album Artist"), + (value: "title", label: "Title"), + (value: "filename", label: "Filename"), + (value: "genre", label: "Genre"), + ], + ), + artists: ( + album_display_mode: SplitByDate, + album_sort_by: Date, + ), + tabs: [ + ( + name: "Queue", + pane: Split( + direction: Horizontal, + panes: [(size: "100%", pane: Pane(Queue))], + ), + ), + ( + name: "Dirs", + pane: Pane(Directories), + ), + ( + name: "Artists", + pane: Pane(Artists), + ), + ( + name: "Albums", + pane: Pane(Albums), + ), + ( + name: "Playlists", + pane: Pane(Playlists), + ), + ], +) + diff --git a/rmpc/themes/kolinux.ron b/rmpc/themes/kolinux.ron new file mode 100644 index 0000000..48b8b2c --- /dev/null +++ b/rmpc/themes/kolinux.ron @@ -0,0 +1,182 @@ +#![enable(implicit_some)] +#![enable(unwrap_newtypes)] +#![enable(unwrap_variant_newtypes)] +( + default_album_art_path: "/home/greg/Pictures/Fetch/atheism_paint.png", + show_song_table_header: true, + draw_borders: true, + format_tag_separator: " | ", + browser_column_widths: [20, 38, 42], + background_color: None, + text_color: None, + header_background_color: None, + modal_background_color: None, + modal_backdrop: false, + preview_label_style: (fg: "yellow"), + preview_metadata_group_style: (fg: "yellow", modifiers: "Bold"), + tab_bar: ( + enabled: true, + active_style: (fg: "black", bg: "blue", modifiers: "Bold"), + inactive_style: (), + ), + highlighted_item_style: (fg: "blue", modifiers: "Bold"), + current_item_style: (fg: "black", bg: "blue", modifiers: "Bold"), + borders_style: (fg: "blue"), + highlight_border_style: (fg: "blue"), + symbols: ( + song: "S", + dir: "D", + playlist: "P", + marker: "M", + ellipsis: "...", + song_style: None, + dir_style: None, + playlist_style: None, + ), + level_styles: ( + info: (fg: "blue", bg: "black"), + warn: (fg: "yellow", bg: "black"), + error: (fg: "red", bg: "black"), + debug: (fg: "light_green", bg: "black"), + trace: (fg: "magenta", bg: "black"), + ), + progress_bar: ( + symbols: ["🬋", "󰃚 ", "⠔"], + track_style: (), + elapsed_style: (fg: "blue"), + thumb_style: (fg: "blue"), + ), + scrollbar: ( + symbols: ["│", "█", "▲", "▼"], + track_style: (), + ends_style: (), + thumb_style: (fg: "blue"), + ), + song_table_format: [ + ( + prop: (kind: Property(Title), + default: (kind: Property(Filename)) + ), + width: "60%", + ), + ( + prop: (kind: Property(Artist), + default: (kind: Text("")) + ), + width: "25%", + ), + ( + prop: (kind: Property(Duration), + default: (kind: Text("-")) + ), + width: "15%", + alignment: Right, + ), + ], + components: {}, + layout: Split( + direction: Vertical, + panes: [ + ( + size: "3", + pane: Split( + direction: Horizontal, + panes: [ + ( + size: "5", + pane: Pane(AlbumArt), + ), + ( + size: "99%", + pane: Split( + direction: Vertical, + panes: [ + ( + size: "5", + pane: Pane(Header), + ), + ( + size: "1", + pane: Pane(ProgressBar), + ), + ] + ) + ), + ] + ), + ), + ( + size: "100%", + pane: Pane(TabContent), + ), + ], + ), + header: ( + rows: [ + ( + left: [ + (kind: Property(Status(StateV2(playing_label: "  Playing", paused_label: "  Paused", stopped_label: "  Stopped"))), style: (fg: "yellow", modifiers: "Bold")), + ], + center: [ + (kind: Property(Song(Title)), style: (modifiers: "Bold"), + default: (kind: Property(Song(Filename)), style: (modifiers: "Bold")) + ) + ], + right: [ + (kind: Property(Widget(ScanStatus)), style: (fg: "blue")), + (kind: Property(Widget(Volume)), style: (fg: "blue")) + ] + ), + ( + left: [ + (kind: Property(Status(Elapsed))), + (kind: Text(" / ")), + (kind: Property(Status(Duration))), + ], + center: [ + (kind: Property(Song(Artist)), style: (fg: "yellow", modifiers: "Bold"), + default: (kind: Text(""), style: (fg: "yellow", modifiers: "Bold")) + ), + ], + right: [ + (kind: Text("[ ")), + (kind: Property(Status(RepeatV2( + on_label: "", off_label: "", + on_style: (fg: "blue", modifiers: "Bold"), off_style: (fg: "yellow", modifiers: "Bold"))))), + (kind: Text(" | ")), + (kind: Property(Status(RandomV2( + on_label: "", off_label: "", + on_style: (fg: "blue", modifiers: "Bold"), off_style: (fg: "yellow", modifiers: "Bold"))))), + (kind: Text(" | ")), + (kind: Property(Status(ConsumeV2( + on_label: "󰮯", off_label: "󰮯", oneshot_label: "󰮯󰇊", + on_style: (fg: "blue", modifiers: "Bold"), off_style: (fg: "yellow", modifiers: "Bold"))))), + (kind: Text(" | ")), + (kind: Property(Status(SingleV2( + on_label: "󰎤", off_label: "󰎤", + on_style: (fg: "blue", modifiers: "Bold"), off_style: (fg: "yellow", modifiers: "Bold"))))), + (kind: Text(" ]")), + ] + ), + ], + ), + browser_song_format: [ + ( + kind: Group([ + (kind: Property(Track)), + (kind: Text(" ")), + ]) + ), + ( + kind: Group([ + (kind: Property(Artist)), + (kind: Text(" - ")), + (kind: Property(Title)), + ]), + default: (kind: Property(Filename)) + ), + ], + lyrics: ( + timestamp: false + ) +) diff --git a/swaync/config.json b/swaync/config.json index f13152c..f400789 100644 --- a/swaync/config.json +++ b/swaync/config.json @@ -136,7 +136,7 @@ { "label": "󰐨", "type": "toggle", - "command": "[[ $SWAYNC_TOGGLE_STATE == true ]] && ( systemd-inhibit --why='User request via swaync' --what=sleep:handle-lid-switch sh -c 'echo \"$$\" > \"$XDG_RUNTIME_DIR/swaync-idle.pid\"; while true; do sleep 3600; done' ) || kill $(<\"$XDG_RUNTIME_DIR/swaync-idle.pid\")", + "command": "[[ $SWAYNC_TOGGLE_STATE == true ]] && ( systemd-inhibit --why='User request via swaync' --what=sleep:handle-lid-switch:idle sh -c 'echo \"$$\" > \"$XDG_RUNTIME_DIR/swaync-idle.pid\"; while true; do sleep 3600; done' ) || kill $(<\"$XDG_RUNTIME_DIR/swaync-idle.pid\")", "update-command": "kill -0 $(<\"$XDG_RUNTIME_DIR/swaync-idle.pid\") && echo true || echo false" } ] @@ -170,15 +170,15 @@ "actions": [ { "label": "Razgonnnn", - "command": "powerprofilesctl set performance" + "command": "notify-send -t 2000 ' Power-Profile Performance' && powerprofilesctl set performance" }, { "label": "Balanced", - "command": "powerprofilesctl set balanced" + "command": "notify-send -t 2000 'Power-Profile Balanced' && powerprofilesctl set balanced" }, { "label": "Survival", - "command": "powerprofilesctl set power-saver" + "command": "notify-send -t 2000 'Power-Profile Power-saver' && powerprofilesctl set power-saver" } ] } diff --git a/swaync/scripts/idle_inhibit_check.sh b/swaync/scripts/idle_inhibit_check.sh new file mode 100755 index 0000000..0b787bc --- /dev/null +++ b/swaync/scripts/idle_inhibit_check.sh @@ -0,0 +1 @@ +pgrep hypridle && echo false || echo true diff --git a/swaync/scripts/idle_inhibit_toggle.sh b/swaync/scripts/idle_inhibit_toggle.sh new file mode 100755 index 0000000..22338e8 --- /dev/null +++ b/swaync/scripts/idle_inhibit_toggle.sh @@ -0,0 +1,10 @@ +kill -0 $(<\"$XDG_RUNTIME_DIR/swaync-idle.pid\") && echo true || echo false +if [ $1 == "on" ]; then + pkill hypridle + systemd-inhibit --why='User request via swaync' --what=sleep:handle-lid-switch sh -c 'echo \"$$\" > \"$XDG_RUNTIME_DIR/swaync-idle.pid\"; while true; do sleep 3600; done' +elif [ $2 == "off" ]; then + hypridle & disown + kill $(<\"$XDG_RUNTIME_DIR/swaync-idle.pid\") +else + exit 1 +fi diff --git a/waybar/config.jsonc b/waybar/config.jsonc index eeb8c89..f812c0f 100644 --- a/waybar/config.jsonc +++ b/waybar/config.jsonc @@ -50,7 +50,7 @@ ], "format": "{icon}", "format-icons": { - "1": "", + "1": " ", "2": "二", "3": "三", "4": "四", @@ -94,7 +94,7 @@ "artist-len": 30, "title-len": 45, "unknown-tag": "n/a", - "format": "{stateIcon} {artist} - {title}", + "format": "{stateIcon} {titleSmart}", "interval": 1, "single-icons": { "on": "1 " diff --git a/waybar/config2.jsonc b/waybar/config2.jsonc deleted file mode 100644 index 173b005..0000000 --- a/waybar/config2.jsonc +++ /dev/null @@ -1,237 +0,0 @@ -// -*- mode: jsonc -*- -{ - // "output": "", - // "layer": "top", // Waybar at top layer - // "position": "bottom", // Waybar position (top|bottom|left|right) - "height": 30, // Waybar height (to be removed for auto height) - // "width": 1280, // Waybar width - "spacing": 4, // Gaps between modules (4px) - // Choose the order of the modules - "modules-left": [ - "hyprland/workspaces", - "idle_inhibitor" - ], - "modules-center": [ - "mpd" - ], - "modules-right": [ - "power-profiles-daemon", - "pulseaudio", - "network", - "cpu", - "memory", - "temperature", - //"backlight", - //"hyprland/language", - "battery", - //"battery#bat2", - "tray", - "clock" - // "custom/power" - ], - // Modules configuration - "hyprland/workspaces": { - "disable-scroll": true, - "all-outputs": false, - "warp-on-scroll": false, - "persistent-workspaces": { - "1": [], - "2": [], - "3": [], - "4": [], - "5": [], - "6": [], - "7": [], - "8": [], - "9": [], - "10": [], - "11": [], - "12": [] - }, - "format": "{icon}", - "format-icons": { - "1": "", - "2": "二", - "3": "三", - "4": "四", - "5": "五", - "6": "六", - "7": "七", - "8": "八", - "9": "九", - "10": "0", - "11": "-", - "12": "+", - // "3": "", - "default": "", - "empty": "" - } - }, - "keyboard-state": { - "numlock": true, - "capslock": true, - "format": "{name} {icon}", - "format-icons": { - "locked": "", - "unlocked": "" - } - }, - "hyprland/language": { - "format-ru": "RU", - "format-en": "EN" - }, - "hyprland/mode": { - "format": "{}" - }, - "hyprland/scratchpad": { - "format": "{icon} {count}", - "show-empty": false, - "format-icons": ["", ""], - "tooltip": true, - "tooltip-format": "{app}: {title}" - }, - "mpd": { - "password": "kapuchinamusica", - "artist-len": 15, - "title-len": 30, - "unknown-tag": "n/a", - "format": "{stateIcon} {artist} - {title} {elapsedTime:%M:%S}/{totalTime:%M:%S}", - "interval": 1, - "single-icons": { - "on": "1 " - }, - "state-icons": { - "paused": "", - "playing": "" - }, - "tooltip-format": "MPD (connected)", - "tooltip-format-disconnected": "MPD (disconnected)", - "on-click": "mpc toggle --password kapuchinamusica" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "", - "deactivated": "" - } - }, - "tray": { - // "icon-size": 21, - "spacing": 10, - "icons": { - "blueman": "bluetooth", - "*": "folder-symbolic" - } - }, - "clock": { - // "timezone": "America/New_York", - "interval": 1, - "tooltip-format": "{:%Y %B}\n{calendar}", - "format": "{:%H:%M:%S}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "{usage}% ", - "tooltip": false, - "interval": 3 - }, - "memory": { - "format": "{}% 󱤓", - "interval": 3 - }, - "temperature": { - // "thermal-zone": 2, - // "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - // "format-critical": "{temperatureC}°C {icon}", - "format": "{temperatureC}°C {icon}", - "format-icons": ["", "", ""] - }, - "backlight": { - // "device": "acpi_video1", - "format": "{percent}% {icon}", - "format-icons": ["", "", "", "", "", "", "", "", ""] - }, - "battery": { - "states": { - "good": 85, - "warning": 30, - "critical": 18 - }, - "format": "{capacity}% {icon}", - "format-full": "{capacity}% {icon}", - "format-charging": "{capacity}% ", - "format-plugged": "{capacity}% ", - "format-alt": "{time} {icon}", - // "format-good": "", // An empty format will hide the module - // "format-full": "", - "format-icons": ["", "", "", "", ""], - "on-click": "gnome-power-statistics" // doesn't work D: - }, - "battery#bat2": { - "bat": "BAT2" - }, - "power-profiles-daemon": { - "format": "{icon}", - "tooltip-format": "Power profile: {profile}\nDriver: {driver}", - "tooltip": true, - "format-icons": { - "default": "󰓅", - "performance": "󰓅", - "balanced": "󰾅", - "power-saver": "󰾆" - } - }, - "network": { - // "interface": "wlp2*", // (Optional) To force the use of this interface - "format-wifi": "{signalStrength}% ", - "format-ethernet": "{ipaddr}/{cidr} ", - "tooltip-format": "{essid} {ifname} via {gwaddr} ", - "format-linked": "{ifname} (No IP) ", - "format-disconnected": "Disconnected ⚠", - "on-click": "hyprctl dispatch exec, [float; move center] kitty -e nmtui" - }, - "pulseaudio": { - // "scroll-step": 1, // %, can be a float - "format": "{volume}% {icon} {format_source}", - "format-bluetooth": "{volume}% {icon} {format_source}", - "format-bluetooth-muted": " {icon} {format_source}", - "format-muted": " {format_source}", - "format-source": "{volume}% ", - "format-source-muted": "", - "format-icons": { - "headphone": "", - //"hands-free": "", - //"headset": "", - "phone": "", - "portable": "", - "car": "", - "default": ["", "", ""] - }, - "on-click": "pwvucontrol" - }, - "custom/media": { - "format": "{icon} {text}", - "return-type": "json", - "max-length": 40, - "format-icons": { - "spotify": "", - "default": "🎜" - }, - "escape": true, - "exec": "$HOME/.config/waybar/mediaplayer.py 2> /dev/null" // Script in resources folder - // "exec": "$HOME/.config/waybar/mediaplayer.py --player spotify 2> /dev/null" // Filter player based on name - }, - "custom/power": { - "format" : "⏻ ", - "tooltip": false, - "menu": "on-click", - "menu-file": "$HOME/.config/waybar/power_menu.xml", // Menu file in resources folder - "menu-actions": { - "shutdown": "shutdown", - "reboot": "reboot", - "suspend": "systemctl suspend", - "hibernate": "systemctl hibernate" - } - } -} diff --git a/waybar/orig/config.jsonc b/waybar/orig/config.jsonc deleted file mode 100644 index 074a0a2..0000000 --- a/waybar/orig/config.jsonc +++ /dev/null @@ -1,201 +0,0 @@ -// -*- mode: jsonc -*- -{ - // "layer": "top", // Waybar at top layer - // "position": "bottom", // Waybar position (top|bottom|left|right) - "height": 30, // Waybar height (to be removed for auto height) - // "width": 1280, // Waybar width - "spacing": 4, // Gaps between modules (4px) - // Choose the order of the modules - "modules-left": [ - "hyprland/workspaces", - "sway/mode", - "sway/scratchpad", - "custom/media" - ], - "modules-center": [ - "sway/window" - ], - "modules-right": [ - "mpd", - "idle_inhibitor", - "pulseaudio", - "network", - "power-profiles-daemon", - "cpu", - "memory", - "temperature", - "backlight", - "keyboard-state", - "sway/language", - "battery", - "battery#bat2", - "clock", - "tray", - "custom/power" - ], - // Modules configuration - "hyprland/workspaces": { - "disable-scroll": true, - "all-outputs": true, - "warp-on-scroll": false, - "format": "{name}: {icon}", - "format-icons": { - "9": "", - "1": "", - // "3": "", - // "4": "", - "8": "", - "urgent": "", - "focused": "", - "default": "" - } - }, - "keyboard-state": { - "numlock": true, - "capslock": true, - "format": "{name} {icon}", - "format-icons": { - "locked": "", - "unlocked": "" - } - }, - "sway/mode": { - "format": "{}" - }, - "sway/scratchpad": { - "format": "{icon} {count}", - "show-empty": false, - "format-icons": ["", ""], - "tooltip": true, - "tooltip-format": "{app}: {title}" - }, - "mpd": { - "password": "kapuchinamusica", - "single-icons": { - "on": "1 " - }, - "state-icons": { - "paused": "", - "playing": "" - }, - "tooltip-format": "MPD (connected)", - "tooltip-format-disconnected": "MPD (disconnected)" - }, - "idle_inhibitor": { - "format": "{icon}", - "format-icons": { - "activated": "", - "deactivated": "" - } - }, - "tray": { - // "icon-size": 21, - "spacing": 10 - }, - "clock": { - // "timezone": "America/New_York", - "tooltip-format": "{:%Y %B}\n{calendar}", - "format-alt": "{:%Y-%m-%d}" - }, - "cpu": { - "format": "{usage}% ", - "tooltip": false - }, - "memory": { - "format": "{}% " - }, - "temperature": { - // "thermal-zone": 2, - // "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - // "format-critical": "{temperatureC}°C {icon}", - "format": "{temperatureC}°C {icon}", - "format-icons": ["", "", ""] - }, - "backlight": { - // "device": "acpi_video1", - "format": "{percent}% {icon}", - "format-icons": ["", "", "", "", "", "", "", "", ""] - }, - "battery": { - "states": { - // "good": 95, - "warning": 30, - "critical": 15 - }, - "format": "{capacity}% {icon}", - "format-full": "{capacity}% {icon}", - "format-charging": "{capacity}% ", - "format-plugged": "{capacity}% ", - "format-alt": "{time} {icon}", - // "format-good": "", // An empty format will hide the module - // "format-full": "", - "format-icons": ["", "", "", "", ""] - }, - "battery#bat2": { - "bat": "BAT2" - }, - "power-profiles-daemon": { - "format": "{icon}", - "tooltip-format": "Power profile: {profile}\nDriver: {driver}", - "tooltip": true, - "format-icons": { - "default": "", - "performance": "", - "balanced": "", - "power-saver": "" - } - }, - "network": { - // "interface": "wlp2*", // (Optional) To force the use of this interface - "format-wifi": "{essid} ({signalStrength}%) ", - "format-ethernet": "{ipaddr}/{cidr} ", - "tooltip-format": "{ifname} via {gwaddr} ", - "format-linked": "{ifname} (No IP) ", - "format-disconnected": "Disconnected ⚠", - "format-alt": "{ifname}: {ipaddr}/{cidr}" - }, - "pulseaudio": { - // "scroll-step": 1, // %, can be a float - "format": "{volume}% {icon} {format_source}", - "format-bluetooth": "{volume}% {icon} {format_source}", - "format-bluetooth-muted": " {icon} {format_source}", - "format-muted": " {format_source}", - "format-source": "{volume}% ", - "format-source-muted": "", - "format-icons": { - "headphone": "", - "hands-free": "", - "headset": "", - "phone": "", - "portable": "", - "car": "", - "default": ["", "", ""] - }, - "on-click": "pavucontrol" - }, - "custom/media": { - "format": "{icon} {text}", - "return-type": "json", - "max-length": 40, - "format-icons": { - "spotify": "", - "default": "🎜" - }, - "escape": true, - "exec": "$HOME/.config/waybar/mediaplayer.py 2> /dev/null" // Script in resources folder - // "exec": "$HOME/.config/waybar/mediaplayer.py --player spotify 2> /dev/null" // Filter player based on name - }, - "custom/power": { - "format" : "⏻ ", - "tooltip": false, - "menu": "on-click", - "menu-file": "$HOME/.config/waybar/power_menu.xml", // Menu file in resources folder - "menu-actions": { - "shutdown": "shutdown", - "reboot": "reboot", - "suspend": "systemctl suspend", - "hibernate": "systemctl hibernate" - } - } -} diff --git a/waybar/orig/style.css b/waybar/orig/style.css deleted file mode 100644 index 7e83028..0000000 --- a/waybar/orig/style.css +++ /dev/null @@ -1,327 +0,0 @@ -* { - /* `otf-font-awesome` is required to be installed for icons */ - font-family: FontAwesome, Roboto, Helvetica, Arial, sans-serif; - font-size: 13px; -} - -window#waybar { - background-color: rgba(43, 48, 59, 0.5); - border-bottom: 3px solid rgba(100, 114, 125, 0.5); - color: #ffffff; - transition-property: background-color; - transition-duration: .5s; -} - -window#waybar.hidden { - opacity: 0.2; -} - -/* -window#waybar.empty { - background-color: transparent; -} -window#waybar.solo { - background-color: #FFFFFF; -} -*/ - -window#waybar.termite { - background-color: #3F3F3F; -} - -window#waybar.chromium { - background-color: #000000; - border: none; -} - -button { - /* Use box-shadow instead of border so the text isn't offset */ - box-shadow: inset 0 -3px transparent; - /* Avoid rounded borders under each button name */ - border: none; - border-radius: 0; -} - -/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ -button:hover { - background: inherit; - box-shadow: inset 0 -3px #ffffff; -} - -/* you can set a style on hover for any module like this */ -#pulseaudio:hover { - background-color: #a37800; -} - -#workspaces button { - padding: 0 5px; - background-color: transparent; - color: #ffffff; -} - -#workspaces button:hover { - background: rgba(0, 0, 0, 0.2); -} - -#workspaces button.focused { - background-color: #64727D; - box-shadow: inset 0 -3px #ffffff; -} - -#workspaces button.urgent { - background-color: #eb4d4b; -} - -#mode { - background-color: #64727D; - box-shadow: inset 0 -3px #ffffff; -} - -#clock, -#battery, -#cpu, -#memory, -#disk, -#temperature, -#backlight, -#network, -#pulseaudio, -#wireplumber, -#custom-media, -#tray, -#mode, -#idle_inhibitor, -#scratchpad, -#power-profiles-daemon, -#mpd { - padding: 0 10px; - color: #ffffff; -} - -#window, -#workspaces { - margin: 0 4px; -} - -/* If workspaces is the leftmost module, omit left margin */ -.modules-left > widget:first-child > #workspaces { - margin-left: 0; -} - -/* If workspaces is the rightmost module, omit right margin */ -.modules-right > widget:last-child > #workspaces { - margin-right: 0; -} - -#clock { - background-color: #64727D; -} - -#battery { - background-color: #ffffff; - color: #000000; -} - -#battery.charging, #battery.plugged { - color: #ffffff; - background-color: #26A65B; -} - -@keyframes blink { - to { - background-color: #ffffff; - color: #000000; - } -} - -/* Using steps() instead of linear as a timing function to limit cpu usage */ -#battery.critical:not(.charging) { - background-color: #f53c3c; - color: #ffffff; - animation-name: blink; - animation-duration: 0.5s; - animation-timing-function: steps(12); - animation-iteration-count: infinite; - animation-direction: alternate; -} - -#power-profiles-daemon { - padding-right: 15px; -} - -#power-profiles-daemon.performance { - background-color: #f53c3c; - color: #ffffff; -} - -#power-profiles-daemon.balanced { - background-color: #2980b9; - color: #ffffff; -} - -#power-profiles-daemon.power-saver { - background-color: #2ecc71; - color: #000000; -} - -label:focus { - background-color: #000000; -} - -#cpu { - background-color: #2ecc71; - color: #000000; -} - -#memory { - background-color: #9b59b6; -} - -#disk { - background-color: #964B00; -} - -#backlight { - background-color: #90b1b1; -} - -#network { - background-color: #2980b9; -} - -#network.disconnected { - background-color: #f53c3c; -} - -#pulseaudio { - background-color: #f1c40f; - color: #000000; -} - -#pulseaudio.muted { - background-color: #90b1b1; - color: #2a5c45; -} - -#wireplumber { - background-color: #fff0f5; - color: #000000; -} - -#wireplumber.muted { - background-color: #f53c3c; -} - -#custom-media { - background-color: #66cc99; - color: #2a5c45; - min-width: 100px; -} - -#custom-media.custom-spotify { - background-color: #66cc99; -} - -#custom-media.custom-vlc { - background-color: #ffa000; -} - -#temperature { - background-color: #f0932b; -} - -#temperature.critical { - background-color: #eb4d4b; -} - -#tray { - background-color: #2980b9; -} - -#tray > .passive { - -gtk-icon-effect: dim; -} - -#tray > .needs-attention { - -gtk-icon-effect: highlight; - background-color: #eb4d4b; -} - -#idle_inhibitor { - background-color: #2d3436; -} - -#idle_inhibitor.activated { - background-color: #ecf0f1; - color: #2d3436; -} - -#mpd { - background-color: #66cc99; - color: #2a5c45; -} - -#mpd.disconnected { - background-color: #f53c3c; -} - -#mpd.stopped { - background-color: #90b1b1; -} - -#mpd.paused { - background-color: #51a37a; -} - -#language { - background: #00b093; - color: #740864; - padding: 0 5px; - margin: 0 5px; - min-width: 16px; -} - -#keyboard-state { - background: #97e1ad; - color: #000000; - padding: 0 0px; - margin: 0 5px; - min-width: 16px; -} - -#keyboard-state > label { - padding: 0 5px; -} - -#keyboard-state > label.locked { - background: rgba(0, 0, 0, 0.2); -} - -#scratchpad { - background: rgba(0, 0, 0, 0.2); -} - -#scratchpad.empty { - background-color: transparent; -} - -#privacy { - padding: 0; -} - -#privacy-item { - padding: 0 5px; - color: white; -} - -#privacy-item.screenshare { - background-color: #cf5700; -} - -#privacy-item.audio-in { - background-color: #1ca000; -} - -#privacy-item.audio-out { - background-color: #0069d4; -} diff --git a/waybar/origcolors.css b/waybar/origcolors.css deleted file mode 100644 index 7a5326c..0000000 --- a/waybar/origcolors.css +++ /dev/null @@ -1,351 +0,0 @@ -* { - /* `otf-font-awesome` is required to be installed for icons */ - font-family: Iosevka, Roboto, Helvetica, Arial, sans-serif; - font-size: 13px; -} - -window#waybar { - background-color: rgba(43, 48, 59, 0.5); - border-bottom: 3px solid rgba(100, 114, 125, 0.5); - color: #ffffff; - transition-property: background-color; - transition-duration: .5s; -} - -window#waybar.hidden { - opacity: 0.2; -} - -/* -window#waybar.empty { - background-color: transparent; -} -window#waybar.solo { - background-color: #FFFFFF; -} -*/ - -window#waybar.termite { - background-color: #3F3F3F; -} - -window#waybar.chromium { - background-color: #000000; - border: none; -} - -button { - /* Use box-shadow instead of border so the text isn't offset */ - box-shadow: inset 0 -3px transparent; - /* Avoid rounded borders under each button name */ - border: none; - border-radius: 0; -} - -/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ -button:hover { - background: inherit; - box-shadow: inset 0 -3px #ffffff; -} - -/* you can set a style on hover for any module like this */ -#pulseaudio:hover { - background-color: #a37800; -} - -#workspaces button { - padding: 0 5px; - background-color: transparent; - color: #ffffff; -} - -#workspaces button.empty { - color: #999999; -} - -#workspaces button:hover { - background: rgba(0, 0, 0, 0.2); -} - -#workspaces button.active { - background-color: #64727D; - box-shadow: inset 0 -3px #ffffff; -} - -#workspaces button.urgent { - background-color: #eb4d4b; -} - -#mode { - background-color: #64727D; - box-shadow: inset 0 -3px #ffffff; -} - -#clock, -#battery, -#cpu, -#memory, -#disk, -#temperature, -#backlight, -#network, -#pulseaudio, -#wireplumber, -#custom-media, -#tray, -#mode, -#idle_inhibitor, -#scratchpad, -#power-profiles-daemon, -#mpd { - padding: 0 10px; - background-color: #B12761; - color: #ffffff; -} - -#window, -#workspaces { - margin: 0 4px; -} - -/* If workspaces is the leftmost module, omit left margin */ -.modules-left > widget:first-child > #workspaces { - margin-left: 0; -} - -/* If workspaces is the rightmost module, omit right margin */ -.modules-right > widget:last-child > #workspaces { - margin-right: 0; -} - -#clock { - background-color: #64727D; -} - -#battery { - background-color: #ffffff; - color: #000000; -} - -#battery.charging, #battery.plugged { - color: #ffffff; - background-color: #26A65B; -} - -@keyframes blink { - to { - background-color: #ffffff; - color: #000000; - } -} - -/* Using steps() instead of linear as a timing function to limit cpu usage */ -#battery.critical:not(.charging) { - background-color: #f53c3c; - color: #ffffff; - animation-name: blink; - animation-duration: 0.5s; - animation-timing-function: steps(12); - animation-iteration-count: infinite; - animation-direction: alternate; -} - -#power-profiles-daemon { - padding-right: 15px; -} - -#power-profiles-daemon.performance { - background-color: #f53c3c; - color: #ffffff; -} - -#power-profiles-daemon.balanced { - background-color: #2980b9; - color: #ffffff; -} - -#power-profiles-daemon.power-saver { - background-color: #2ecc71; - color: #000000; -} - -label:focus { - background-color: #000000; -} - -#cpu { - background-color: #2ecc71; - color: #000000; -} - -#memory { - background-color: #9b59b6; -} - -#disk { - background-color: #964B00; -} - -#backlight { - background-color: #90b1b1; -} - -#network { - background-color: #2980b9; -} - -#network.disconnected { - background-color: #f53c3c; -} - -#pulseaudio { - background-color: #f1c40f; - color: #000000; -} - -#pulseaudio.muted { - background-color: #90b1b1; - color: #2a5c45; -} - -#wireplumber { - background-color: #fff0f5; - color: #000000; -} - -#wireplumber.muted { - background-color: #f53c3c; -} - -#custom-media { - background-color: #66cc99; - color: #2a5c45; - min-width: 100px; -} - -#custom-media.custom-spotify { - background-color: #66cc99; -} - -#custom-media.custom-vlc { - background-color: #ffa000; -} - -#temperature { - background-color: #f0932b; -} - -#temperature.critical { - background-color: #eb4d4b; -} - -#tray { - background-color: #2980b9; -} - -#tray > .passive { - -gtk-icon-effect: dim; -} - -#tray > .needs-attention { - -gtk-icon-effect: highlight; - background-color: #eb4d4b; -} - -#idle_inhibitor { - background-color: #2d3436; -} - -@keyframes idle_blink { - 0% { - background-color: #ffffff; - } - 80% { - background-color: #ffffff; - } - 100% { - background-color: #FF0000; - } -} - -#idle_inhibitor.activated { - /*background-color: #ecf0f1; - color: #2d3436;*/ - background-color: #ffffff; - color: #2d3436; - animation: idle_blink 2s infinite; - - animation-name: idle_blink; - animation-duration: 5.0s; - animation-timing-function: steps(64); - animation-iteration-count: infinite; - animation-direction: alternate; -} - -#mpd { - background-color: #66cc99; - color: #2a5c45; -} - -#mpd.disconnected { - background-color: #f53c3c; -} - -#mpd.stopped { - background-color: #90b1b1; -} - -#mpd.p000000{ - background-color: #51a37a; -} - -#keyboard-state { - background: #97e1ad; - color: #000000; - padding: 0 0px; - margin: 0 5px; - min-width: 16px; -} - -#language { - background: #2980b9; - color: #ffffff; - padding: 0 5px; - min-width: 16px; -} - -#keyboard-state > label { - padding: 0 5px; -} - -#keyboard-state > label.locked { - background: rgba(0, 0, 0, 0.2); -} - -#scratchpad { - background: rgba(0, 0, 0, 0.2); -} - -#scratchpad.empty { - background-color: transparent; -} - -#privacy { - padding:0000} - -#privacy-item { - padding: 0 5px; - color: white; -} - -#privacy-item.screenshare { - background-color: #cf5700; -} - -#privacy-item.audio-in { - background-color: #1ca000; -} - -#privacy-item.audio-out { - background-color: #0069d4; -} diff --git a/waybar/style.css b/waybar/style.css index d8f4496..a569f89 100644 --- a/waybar/style.css +++ b/waybar/style.css @@ -31,15 +31,19 @@ window#waybar { border-radius: 0 0 0 10px; } +#mpd.stopped { + border: none; + border-radius: 0 0 10px 10px; + transition-property: background-color; + transition-duration: 2s; +} + #mpd.playing, #mpd.paused { border-radius: 0 0 10px 10px; + transition-property: background-color; + transition-duration: 2s; } -#mpd.playing { -} - -@keyframes gradientShift { -} window#waybar.hidden { opacity: 0.2;