From 4f7cce1b8e7c2ddc10edfd6cc0a50be24082a8d6 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Fri, 10 Sep 2021 00:46:17 -0600 Subject: [PATCH] [taffybar] Specify bar size as a ScreenRatio --- dotfiles/config/taffybar/taffybar | 2 +- dotfiles/config/taffybar/taffybar.hs | 16 +++++++++------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/dotfiles/config/taffybar/taffybar b/dotfiles/config/taffybar/taffybar index c901f1f5..af67fdf4 160000 --- a/dotfiles/config/taffybar/taffybar +++ b/dotfiles/config/taffybar/taffybar @@ -1 +1 @@ -Subproject commit c901f1f5d1ec7e885c15e349458faea7f26b6660 +Subproject commit af67fdf4c5079770c2b1ebcb2c46697a9da42261 diff --git a/dotfiles/config/taffybar/taffybar.hs b/dotfiles/config/taffybar/taffybar.hs index be5a5926..ecae42fc 100644 --- a/dotfiles/config/taffybar/taffybar.hs +++ b/dotfiles/config/taffybar/taffybar.hs @@ -135,6 +135,8 @@ cssFilesByHostname = ] main = do + enableLogger "Graphics.UI.GIGtkStrut" DEBUG + hostName <- getHostName homeDirectory <- getHomeDirectory let relativeFiles = fromMaybe ["taffybar.css"] $ lookup hostName cssFilesByHostname @@ -201,10 +203,10 @@ main = do defaultSimpleTaffyConfig { startWidgets = [myWorkspaces, myLayout, myWindows] , endWidgets = fullEndWidgets - , barPosition = Top + , barPosition = Bottom , widgetSpacing = 0 , barPadding = 0 - , barHeight = 50 + , barHeight = ScreenRatio $ 1/27 , cssPaths = cssFiles , startupHook = void $ setCMCAPIKey "f9e66366-9d42-4c6e-8d40-4194a0aaa329" } @@ -214,19 +216,19 @@ main = do , baseConfig { endWidgets = laptopEndWidgets } ) , ( "imalison-home" - , baseConfig { endWidgets = fullEndWidgets, barHeight = 42 } + , baseConfig { endWidgets = fullEndWidgets } ) , ( "ryzen-shine" - , baseConfig { endWidgets = fullEndWidgets, barHeight = 50 } + , baseConfig { endWidgets = fullEndWidgets } ) , ( "ivanm-dfinity-razer" - , baseConfig { endWidgets = laptopEndWidgets, barHeight = 42 } + , baseConfig { endWidgets = laptopEndWidgets } ) , ( "adele" - , baseConfig { endWidgets = laptopEndWidgets, barHeight = 45 } + , baseConfig { endWidgets = laptopEndWidgets } ) , ( "stevie-nixos" - , baseConfig { endWidgets = laptopEndWidgets, barHeight = 70 } + , baseConfig { endWidgets = laptopEndWidgets } ) ] simpleTaffyConfig = selectedConfig