aboutsummaryrefslogtreecommitdiffstats
path: root/modules/desktop/status-bar/polybar/bar/main.nix
diff options
context:
space:
mode:
authorArpit Chakladar <54011232+arpitchakladar@users.noreply.github.com>2024-09-28 00:04:49 +0530
committerArpit Chakladar <54011232+arpitchakladar@users.noreply.github.com>2024-09-28 00:04:49 +0530
commit4d315448c08f98140229f006898dc408fcb6953e (patch)
tree3332f70f724eeae34cf17be5020fe1b4953ba374 /modules/desktop/status-bar/polybar/bar/main.nix
parentb20945970ba46999c8c4f234ea0456ca368e179a (diff)
downloadhome-manager-config-4d315448c08f98140229f006898dc408fcb6953e.tar.gz
home-manager-config-4d315448c08f98140229f006898dc408fcb6953e.zip
Few minor tweaks to polybar.
Diffstat (limited to 'modules/desktop/status-bar/polybar/bar/main.nix')
-rw-r--r--modules/desktop/status-bar/polybar/bar/main.nix16
1 files changed, 10 insertions, 6 deletions
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";
}