Improve Waybar config: add tray and idle_inhibitor, clock calendar tooltip, weather on-click, portable power profile via powerprofilesctl, enhanced battery/temp tooltips, backlight scroll; update CSS for idle_inhibitor and fix bluetooth semicolon

This commit is contained in:
nicholai 2025-09-08 04:21:17 -06:00
parent fa1ef980b1
commit 8672155b0a
2 changed files with 44 additions and 30 deletions

View File

@ -8,9 +8,11 @@
"height": 20,
"modules-left": ["clock","custom/weather","custom/wallpaper","hyprland/window"],
"modules-center": ["hyprland/workspaces"],
"modules-right": ["network", "bluetooth", "temperature","custom/power_profile","battery","backlight","pulseaudio","pulseaudio#microphone"],
"modules-right": ["network", "bluetooth", "temperature","custom/power_profile","battery","backlight","pulseaudio","pulseaudio#microphone","tray","idle_inhibitor"],
"hyprland/window": {
"format": "{}"
"format": "{}",
"max-length": 60,
"tooltip": true
},
@ -40,13 +42,13 @@
},
"custom/power_profile":{
//shows the current power profile and switches to next on click
// "exec": "asusctl profile -p | sed s:'Active profile is'::",
"interval": 30,
"format": "󰈐{}",
// "on-click": "asusctl profile -n; pkill -SIGRTMIN+8 waybar",
"signal": 8
"custom/power_profile": {
"exec": "powerprofilesctl get",
"interval": 5,
"format": "󰈐 {}",
"on-click": "pp=$(powerprofilesctl get); case \"$pp\" in performance) n=balanced;; balanced) n=powersave;; *) n=performance;; esac; powerprofilesctl set \"$n\"; pkill -SIGRTMIN+8 waybar",
"signal": 8,
"return-type": "string"
},
"custom/weather" : {
@ -55,32 +57,40 @@
"format" : "{}",
"interval" : 30,
"exec" : "~/.config/waybar/scripts/waybar-wttr.py",
"return-type" : "json"
"return-type" : "json",
"on-click": "xdg-open https://wttr.in"
},
// "tray": {
// "icon-size": 18,
// "spacing": 10
// },
"tray": {
"icon-size": 18,
"spacing": 10
},
// "clock": {
// "format": "{: %I:%M %p  %a, %b %e}",
// "tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>"
// },
"clock": {
"format": "{:%I:%M %p}" // hours:minutes AM/PM
// or 24-hour: "{:%H:%M}"
"format": "{:%I:%M %p}",
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>"
},
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "󰒳",
"deactivated": "󰒲"
},
"tooltip": true
},
// "backlight": {
// "device": "intel_backlight",
// "format": "{icon} {percent}%",
// "format-icons": ["󰃞", "󰃟", "󰃠"],
// "on-scroll-up": "brightnessctl set 1%+",
// "on-scroll-down": "brightnessctl set 1%-",
// "min-length": 6
// },
"backlight": {
"format": "{icon} {percent}%",
"format-icons": ["󰃞", "󰃟", "󰃠"],
"on-scroll-up": "brightnessctl set 5%+",
"on-scroll-down": "brightnessctl set 5%-",
"min-length": 6
},
"battery": {
"states": {
@ -92,7 +102,9 @@
"format-charging": " {capacity}%",
"format-plugged": " {capacity}%",
"format-alt": "{time} {icon}",
"format-icons": ["󰂎", "󰁺", "󰁻", "󰁼", "󰁽", "󰁾", "󰁿", "󰂀", "󰂁", "󰂂", "󰁹"]
"format-icons": ["󰂎", "󰁺", "󰁻", "󰁼", "󰁽", "󰁾", "󰁿", "󰂀", "󰂁", "󰂂", "󰁹"],
"tooltip": true,
"tooltip-format": "{status} • {capacity}%\n{timeTo}\nHealth: {health}"
},
"pulseaudio": {
@ -128,7 +140,8 @@
"thermal-zone": 1,
"format": "{temperatureF}°F ",
"critical-threshold": 80,
"format-critical": "{temperatureC}°C "
"format-critical": "{temperatureF}°F ",
"tooltip": true
},
"network": {
@ -149,4 +162,4 @@
"tooltip-format-enumerate-connected": "{device_alias}",
"on-click": "blueman-manager" // launch the GUI when you leftclick
}
}
}

View File

@ -58,7 +58,8 @@ window#waybar {
#temperature,
#workspaces,
#tray,
#backlight {
#backlight,
#idle_inhibitor {
background: @background;
color: @color12;
opacity: 0.8;
@ -141,7 +142,7 @@ window#waybar {
color: @color5;
background: @background;
border-radius: 0px 5px 5px 0px;
margin-right: 10px
margin-right: 10px;
}
#pulseaudio {
@ -172,4 +173,4 @@ window#waybar {
border-radius: 0px 5px 5px 0px;
border-right: 0px;
margin-left: 0px;
}
}