I don't know if this is the best way to do it but this one-liner
makes it look exactly like dwm's.
---
src/bar.cpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/bar.cpp b/src/bar.cpp
index af92f49..ea2e5bc 100644
--- a/src/bar.cpp+++ b/src/bar.cpp
@@ -263,6 +263,7 @@ void Bar::renderStatus()
beginBg();
auto start = _bufs->width - _statusCmp.width() - paddingX*2;
cairo_rectangle(_painter, _x, 0, _bufs->width-_x+start, _bufs->height);
+ setColorScheme(colorInactive, false); cairo_fill(_painter);
_x = start;
--
2.43.0
FWIW, I instead initialize the variable lastStatus to "dwl" in
main.cpp to avoid the empty padding. Plus I like how it looks :)
Cheers,
diff --git a/src/main.cpp b/src/main.cpp
index 15a749a..f784e6b 100644
--- a/src/main.cpp+++ b/src/main.cpp
@@ -76,7 +76,7 @@ static std::list<Monitor> monitors;
static std::vector<std::pair<uint32_t, wl_output*>> uninitializedOutputs;
static std::list<Seat> seats;
static Monitor* selmon;
-static std::string lastStatus;+static std::string lastStatus = "dwl";static std::string statusFifoName;
static std::vector<pollfd> pollfds;
static std::array<int, 2> signalSelfPipe;
El vie, 16 feb 2024 a las 9:19, Raphael Robatsch
(<raphael@tapesoftware.net>) escribió:
>
> Thanks, applied with minor changes to remove the padding if no status exists.
>
> To git.sr.ht:~raphi/somebar
> 7433a1f..6572b98 master -> master
--
··············································