Redesign polybar layout
Use material design icons for consistency Add bluetooth and audio control modules Reduce verbosity, using icons for compactness Remove some modules
This commit is contained in:
parent
2ebc666a7b
commit
30366d6aea
161
nixos/home-manager/env/config/polybar/polybar.ini
vendored
161
nixos/home-manager/env/config/polybar/polybar.ini
vendored
|
@ -59,133 +59,140 @@
|
|||
alert = ${colors.red}
|
||||
disabled = ${colors.surface0}
|
||||
|
||||
[bar/example]
|
||||
width = 100%
|
||||
[common]
|
||||
height = 24pt
|
||||
radius = 6
|
||||
|
||||
dpi = 96
|
||||
|
||||
dpi = 0
|
||||
font-0 = FiraCode Nerd Font;size=12
|
||||
font-1 = Iosevka Nerd Font;size=12
|
||||
font-2 = Noto Sans;size=12
|
||||
line-size = 3pt
|
||||
background = ${colors.background}
|
||||
foreground = ${colors.foreground}
|
||||
|
||||
line-size = 3pt
|
||||
|
||||
border-size = 4pt
|
||||
border-color = ${colors.transparent}
|
||||
|
||||
padding-left = 0
|
||||
padding-right = 1
|
||||
|
||||
padding = 1
|
||||
module-margin = 1
|
||||
|
||||
border-size = 4pt
|
||||
border-color = ${colors.background}
|
||||
wm-restack = generic
|
||||
override-redirect = false
|
||||
separator = |
|
||||
separator-foreground = ${colors.disabled}
|
||||
|
||||
font-0 = FiraCode Nerd Font;2
|
||||
|
||||
modules-left = xworkspaces xwindow
|
||||
modules-right = filesystem alsa xkeyboard memory cpu wlan eth date
|
||||
|
||||
cursor-click = pointer
|
||||
cursor-scroll = ns-resize
|
||||
|
||||
enable-ipc = true
|
||||
|
||||
tray-position = right
|
||||
wm-restack = bspwm
|
||||
override-redirect = false
|
||||
[settings]
|
||||
screenchange-reload = true
|
||||
pseudo-transparency = false
|
||||
|
||||
[bar/main]
|
||||
inherit = common
|
||||
width = 100%
|
||||
|
||||
modules-left = launcher xworkspaces
|
||||
modules-right = pulseaudio-control-sink pulseaudio-control-source memory cpu bluetooth wlan eth date power-menu
|
||||
|
||||
[module/launcher]
|
||||
type = custom/text
|
||||
content = " "
|
||||
click-left = "rofi -show drun &"
|
||||
|
||||
[module/power-menu]
|
||||
type = custom/text
|
||||
content = " "
|
||||
click-left = "~/.dotfiles/scripts/powermenu"
|
||||
|
||||
[module/xworkspaces]
|
||||
type = internal/xworkspaces
|
||||
|
||||
label-active = %name%
|
||||
icon-0 = "I; "
|
||||
icon-1 = "II; "
|
||||
icon-2 = "III; "
|
||||
icon-3 = "IV; "
|
||||
icon-4 = "V; "
|
||||
icon-5 = "VI; "
|
||||
icon-6 = "VII; "
|
||||
icon-7 = "VIII; "
|
||||
icon-8 = "IX; "
|
||||
icon-9 = "X; "
|
||||
|
||||
label-active = %icon%
|
||||
label-active-background = ${colors.background-alt}
|
||||
label-active-underline= ${colors.primary}
|
||||
label-active-padding = 1
|
||||
|
||||
label-occupied = %name%
|
||||
label-occupied = %icon%
|
||||
label-occupied-padding = 1
|
||||
|
||||
label-urgent = %name%
|
||||
label-urgent = %icon%
|
||||
label-urgent-background = ${colors.alert}
|
||||
label-urgent-padding = 1
|
||||
|
||||
label-empty = %name%
|
||||
label-empty = %icon%
|
||||
label-empty-foreground = ${colors.disabled}
|
||||
label-empty-padding = 1
|
||||
|
||||
[module/xwindow]
|
||||
type = internal/xwindow
|
||||
label = %title:0:60:...%
|
||||
[module/pulseaudio-control-sink]
|
||||
type = custom/script
|
||||
label = "%output%"
|
||||
tail = true
|
||||
interval = 0
|
||||
exec = ~/.dotfiles/scripts/pulseaudio-control.bash --icon-muted " " --icons-volume " , , " --node-nicknames-from device.product.name --node-nickname "alsa_output.pci-0000_2d_00.1.hdmi-stereo-extra4.2: " --node-nickname "alsa_output.pci-0000_2f_00.4.analog-stereo.2: " --node-type output output
|
||||
click-left = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type output togmute
|
||||
click-right = exec pavucontrol &
|
||||
click-middle = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type output next-node
|
||||
scroll-up = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type output up
|
||||
scroll-down = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type output down
|
||||
|
||||
[module/filesystem]
|
||||
type = internal/fs
|
||||
interval = 25
|
||||
|
||||
mount-0 = /
|
||||
#mount-1 = /mnt/primary
|
||||
#mount-2 = /mnt/secondary
|
||||
|
||||
label-mounted = %{F#b7bdf8}%mountpoint%%{F-} %percentage_used%%
|
||||
|
||||
label-unmounted = %mountpoint% not mounted
|
||||
label-unmounted-foreground = ${colors.disabled}
|
||||
|
||||
[module/alsa]
|
||||
type = internal/alsa
|
||||
|
||||
format-volume-prefix = "VOL "
|
||||
format-volume-prefix-foreground = ${colors.primary}
|
||||
format-volume = <label-volume>
|
||||
|
||||
label-volume = %percentage%%
|
||||
|
||||
label-muted = muted
|
||||
label-muted-foreground = ${colors.disabled}
|
||||
|
||||
[module/xkeyboard]
|
||||
type = internal/xkeyboard
|
||||
blacklist-0 = num lock
|
||||
|
||||
label-layout = %layout%
|
||||
label-layout-foreground = ${colors.primary}
|
||||
|
||||
label-indicator-padding = 2
|
||||
label-indicator-margin = 1
|
||||
label-indicator-foreground = ${colors.background}
|
||||
label-indicator-background = ${colors.secondary}
|
||||
[module/pulseaudio-control-source]
|
||||
type = custom/script
|
||||
label = "%output%"
|
||||
tail = true
|
||||
interval = 0
|
||||
env-NODE-TYPE = "input"
|
||||
exec = ~/.dotfiles/scripts/pulseaudio-control.bash --icon-muted " " --icons-volume " , , " --node-nickname "alsa_input.pci-0000_2f_00.4.analog-stereo.2: " --node-type input output
|
||||
click-left = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type input togmute
|
||||
click-right = exec pavucontrol &
|
||||
click-middle = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type input next-node
|
||||
scroll-up = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type input up
|
||||
scroll-down = ~/.dotfiles/scripts/pulseaudio-control.bash --node-type input down
|
||||
|
||||
[module/memory]
|
||||
type = internal/memory
|
||||
interval = 2
|
||||
format-prefix = "RAM "
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.primary}
|
||||
label = %percentage_used:2%%
|
||||
|
||||
[module/cpu]
|
||||
type = internal/cpu
|
||||
interval = 2
|
||||
format-prefix = "CPU "
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.primary}
|
||||
label = %percentage:2%%
|
||||
|
||||
[module/bluetooth]
|
||||
type = custom/script
|
||||
exec = ~/.dotfiles/scripts/system-bluetooth-bluetoothctl.sh
|
||||
tail = true
|
||||
interval = 0
|
||||
click-left = ~/.dotfiles/scripts/system-bluetooth-bluetoothctl.sh --toggle &
|
||||
|
||||
[network-base]
|
||||
type = internal/network
|
||||
interval = 5
|
||||
format-connected = <label-connected>
|
||||
format-disconnected = <label-disconnected>
|
||||
label-disconnected = %{F#b7bdf8}%ifname%%{F#ed8796} disconnected
|
||||
|
||||
[module/wlan]
|
||||
inherit = network-base
|
||||
interface-type = wireless
|
||||
label-connected = %{F#b7bdf8}%ifname%%{F-} %essid% %local_ip%
|
||||
label-connected = "%{F#b7bdf8} {F-} %essid%"
|
||||
label-disconnected = "%{F#b7bdf8} "
|
||||
|
||||
[module/eth]
|
||||
inherit = network-base
|
||||
interface-type = wired
|
||||
label-connected = %{F#b7bdf8}%ifname%%{F-} %local_ip%
|
||||
label-connected = "%{F#b7bdf8} "
|
||||
label-disconnected = "%{F#b7bdf8} "
|
||||
|
||||
[module/date]
|
||||
type = internal/date
|
||||
|
@ -197,8 +204,4 @@ date-alt = %Y-%m-%d %H:%M:%S
|
|||
label = %date%
|
||||
label-foreground = ${colors.primary}
|
||||
|
||||
[settings]
|
||||
screenchange-reload = true
|
||||
pseudo-transparency = false
|
||||
|
||||
; vim:ft=dosini
|
||||
|
|
Loading…
Reference in a new issue