From 4d315448c08f98140229f006898dc408fcb6953e Mon Sep 17 00:00:00 2001 From: Arpit Chakladar <54011232+arpitchakladar@users.noreply.github.com> Date: Sat, 28 Sep 2024 00:04:49 +0530 Subject: Few minor tweaks to polybar. --- modules/desktop/status-bar/polybar/bar/main.nix | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'modules/desktop/status-bar/polybar/bar') diff --git a/modules/desktop/status-bar/polybar/bar/main.nix b/modules/desktop/status-bar/polybar/bar/main.nix index d1f05b2..660c444 100644 --- a/modules/desktop/status-bar/polybar/bar/main.nix +++ b/modules/desktop/status-bar/polybar/bar/main.nix @@ -1,7 +1,9 @@ { config }: with config.scheme.withHashtag; -{ +let + largerFontSize = toString (builtins.ceil (config.fonts.size * 9.0 / 8.0)); +in { width = "\${env:POLYBAR_WIDTH}"; fixed-center = false; height = 35; @@ -21,20 +23,22 @@ with config.scheme.withHashtag; padding-left = 1; padding-right = 1; - separator = "%{F${base03}}│%{F-}"; + module-margin-left = 1; + module-margin-right = 1; - module-margin-left = 2; - module-margin-right = 2; + separator = "%{F${base03}}%{T3}│%{T-}%{F-}"; offset-x = "\${env:POLYBAR_OFFSET}"; offset-y = "\${env:POLYBAR_OFFSET}"; font-0 = "${config.fonts.normal}:pixelsize=${toString config.fonts.size};3"; + font-1 = "${config.fonts.normal}:weight=Bold:pixelsize=${largerFontSize};3"; + font-2 = "${config.fonts.normal}:style=Light:pixelsize=${largerFontSize};2"; modules-left = if config.desktop.window-manager.bspwm.enable then - "bspwm" + "bspwm separator" else null; modules-center = "xwindow"; - modules-right = "memory cpu battery time date kernel-version"; + modules-right = "separator memory cpu battery time date kernel-version"; } -- cgit v1.2.3