conformal / spectrwm

A small dynamic tiling window manager for X11.
ISC License
1.33k stars 97 forks source link

Please revert "Strip trailing padding with urgent_collapse" edfc16af9 #96

Closed levaidaniel closed 9 years ago

levaidaniel commented 9 years ago

commit edfc16af9a108c4d9193694fb8c37aa5c1afc0b0 Author: Yuri D'Elia yuri.delia@eurac.edu Date: Mon Sep 8 12:07:59 2014 +0200 Strip trailing padding with urgent_collapse

diff --git a/spectrwm.c b/spectrwm.c
index 03c6259..de42566 100644
--- a/spectrwm.c
+++ b/spectrwm.c
@@ -2227,6 +2227,8 @@ bar_urgent(char *s, size_t sz)
                        strlcat(s, "- ", sz);
                }
        }
+       if(urgent_collapse && s[0])
+               s[strlen(s) - 1] = 0;
 }

 void

This produces silly output in the urgent part of the bar, like: * 1* Notice the space before the workspace number, and not after it. It should read * 1 *. Or if you're against spaces, at least *1*...

LordReg commented 9 years ago

You can customize bar_format to have: *+U* instead of * +U* but it looks like this should be done automatically by urgent_collapse = 1.