From 3919a0045c4a065f67f9f4c39a241641c0da3cf2 Mon Sep 17 00:00:00 2001 From: LemonBoy Date: Sat, 15 Mar 2014 15:07:10 +0000 Subject: [PATCH] Flawless centering --- bar.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bar.c b/bar.c index a2ec3f0..1ccc907 100644 --- a/bar.c +++ b/bar.c @@ -108,7 +108,7 @@ draw_char (monitor_t *mon, font_t *cur_font, int x, int align, uint16_t ch) case ALIGN_C: xcb_copy_area(c, mon->pixmap, mon->pixmap, gc[GC_DRAW], mon->width / 2 - x / 2, 0, mon->width / 2 - (x + ch_width) / 2, 0, x, bh); - x = mon->width / 2 - ch_width / 2 + x / 2; + x = mon->width / 2 - (x + ch_width) / 2 + x; break; case ALIGN_R: xcb_copy_area(c, mon->pixmap, mon->pixmap, gc[GC_DRAW], mon->width - x, 0,