about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBaitinq <manuelpalenzuelamerino@gmail.com>2025-01-04 12:59:57 +0100
committerBaitinq <manuelpalenzuelamerino@gmail.com>2025-01-04 12:59:57 +0100
commit8455dd05415ed24cd039a188280ad6e07b1de457 (patch)
treed428656bd19bf71fd8e7773904010b7af8b87f41
parentOverlays: Dmenu: Update with new font (diff)
downloadnixos-config-8455dd05415ed24cd039a188280ad6e07b1de457.tar.gz
nixos-config-8455dd05415ed24cd039a188280ad6e07b1de457.tar.bz2
nixos-config-8455dd05415ed24cd039a188280ad6e07b1de457.zip
Dotfiles: Xmonad: Limit window title length
-rw-r--r--dotfiles/xmonad.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/dotfiles/xmonad.hs b/dotfiles/xmonad.hs
index a514729..1c061a1 100644
--- a/dotfiles/xmonad.hs
+++ b/dotfiles/xmonad.hs
@@ -238,7 +238,9 @@ myStatusBar = statusBarProp "xmobar" (do
                                                     ppCurrent = if numWindows > 0
                                                                         then xmobarBorder "Top" foregroundColor 4 . xmobarColor foregroundColor backgroundColor . wrap " " " "
                                                                         else xmobarColor foregroundColor backgroundColor . wrap " " " "
-                                                  , ppTitle = id
+                                                  , ppTitle = (\xs -> case length xs > 70 of
+                                                                        True -> take 70 xs ++ "..."
+                                                                        False -> xs) . xmobarStrip
                                                   , ppSep = " |  "
                                                   , ppWsSep = ""
                                                   , ppLayout = (\_ -> "")