mirror of
https://codeberg.org/dwl/dwl-patches.git
synced 2025-10-27 18:24:26 +00:00
barborder: update for bar 2024-05-28
This commit is contained in:
parent
b1198bdbee
commit
1fa069584a
@ -3,7 +3,7 @@
|
|||||||
Add a border around the [bar](https://codeberg.org/dwl/dwl-patches/wiki/bar) similar to how a client is given a border.
|
Add a border around the [bar](https://codeberg.org/dwl/dwl-patches/wiki/bar) similar to how a client is given a border.
|
||||||
|
|
||||||
### Download
|
### Download
|
||||||
- [2024-04-14](https://codeberg.org/dwl/dwl-patches/raw/branch/main/patches/barborder/barborder.patch) (bar 2024-04-14)
|
- [2024-06-03](https://codeberg.org/dwl/dwl-patches/raw/branch/main/patches/barborder/barborder.patch) (bar 2024-05-28)
|
||||||
|
|
||||||
### Authors
|
### Authors
|
||||||
- [sewn](https://codeberg.org/sewn)
|
- [sewn](https://codeberg.org/sewn)
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
From 38dd71e51784ab68261d9c0479a4579d419315f1 Mon Sep 17 00:00:00 2001
|
From aea34ede12983a37aef3ff5a90ba6214fa2db797 Mon Sep 17 00:00:00 2001
|
||||||
From: sewn <sewn@disroot.org>
|
From: sewn <sewn@disroot.org>
|
||||||
Date: Sun, 14 Apr 2024 08:47:04 +0300
|
Date: Mon, 3 Jun 2024 10:27:42 +0300
|
||||||
Subject: [PATCH] add border to bar
|
Subject: [PATCH] add border to bar
|
||||||
|
|
||||||
---
|
---
|
||||||
@ -30,7 +30,7 @@ index 0be3ad0..e5e595a 100644
|
|||||||
static pixman_color_t normbarbg = { 0x2222, 0x2222, 0x2222, 0xffff };
|
static pixman_color_t normbarbg = { 0x2222, 0x2222, 0x2222, 0xffff };
|
||||||
static pixman_color_t selbarfg = { 0xeeee, 0xeeee, 0xeeee, 0xffff };
|
static pixman_color_t selbarfg = { 0xeeee, 0xeeee, 0xeeee, 0xffff };
|
||||||
diff --git a/dwl.c b/dwl.c
|
diff --git a/dwl.c b/dwl.c
|
||||||
index 54273ae..3153bfd 100644
|
index 0268772..96e03ec 100644
|
||||||
--- a/dwl.c
|
--- a/dwl.c
|
||||||
+++ b/dwl.c
|
+++ b/dwl.c
|
||||||
@@ -1344,7 +1344,8 @@ dirtomon(enum wlr_direction dir)
|
@@ -1344,7 +1344,8 @@ dirtomon(enum wlr_direction dir)
|
||||||
@ -101,20 +101,20 @@ index 54273ae..3153bfd 100644
|
|||||||
if (c != NULL) {
|
if (c != NULL) {
|
||||||
- drwl_text(pix, font, x, 0, w, mon->b.height, lrpad / 2,
|
- drwl_text(pix, font, x, 0, w, mon->b.height, lrpad / 2,
|
||||||
+ drwl_text(pix, font, x, y, w, mh, lrpad / 2,
|
+ drwl_text(pix, font, x, y, w, mh, lrpad / 2,
|
||||||
c ? client_get_title(c) : NULL,
|
client_get_title(c),
|
||||||
mon == selmon ? &selbarfg : &normbarfg,
|
mon == selmon ? &selbarfg : &normbarfg,
|
||||||
(mon == selmon && c) ? &selbarbg : &normbarbg);
|
(mon == selmon && c) ? &selbarbg : &normbarbg);
|
||||||
if (c && c->isfloating)
|
if (c && c->isfloating)
|
||||||
- drwl_rect(pix, x + boxs, boxs, boxw, boxw, 0,
|
- drwl_rect(pix, x + boxs, boxs, boxw, boxw, 0,
|
||||||
+ drwl_rect(pix, x + boxs, y + boxs, boxw, boxw, 0,
|
+ drwl_rect(pix, x + boxs, y + boxs, boxw, boxw, 0,
|
||||||
mon == selmon ? &selbarfg : &normbarfg);
|
mon == selmon ? &selbarfg : &normbarfg);
|
||||||
} else {
|
} else
|
||||||
- drwl_rect(pix, x, 0, w, mon->b.height, 1, &normbarbg);
|
- drwl_rect(pix, x, 0, w, mon->b.height, 1, &normbarbg);
|
||||||
+ drwl_rect(pix, x, y, w, mh, 1, &normbarbg);
|
+ drwl_rect(pix, x, y, w, mh, 1, &normbarbg);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2664,7 +2669,7 @@ setup(void)
|
pixman_image_unref(pix);
|
||||||
|
@@ -2663,7 +2668,7 @@ setup(void)
|
||||||
die("Could not load font");
|
die("Could not load font");
|
||||||
|
|
||||||
lrpad = font->height;
|
lrpad = font->height;
|
||||||
@ -124,5 +124,5 @@ index 54273ae..3153bfd 100644
|
|||||||
status_event_source = wl_event_loop_add_fd(wl_display_get_event_loop(dpy),
|
status_event_source = wl_event_loop_add_fd(wl_display_get_event_loop(dpy),
|
||||||
STDIN_FILENO, WL_EVENT_READABLE, status_in, NULL);
|
STDIN_FILENO, WL_EVENT_READABLE, status_in, NULL);
|
||||||
--
|
--
|
||||||
2.44.0
|
2.45.0
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user