From 357a40b586863c5383cdd09909fa8eec6ebda309 Mon Sep 17 00:00:00 2001 From: Sascha Kruse Date: Thu, 23 Aug 2012 00:10:06 +0200 Subject: [PATCH] use correct line index when calculating width --- dunst.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dunst.c b/dunst.c index fdcb2eb..fc3459b 100644 --- a/dunst.c +++ b/dunst.c @@ -543,7 +543,7 @@ void draw_win(void) notification *n = (notification *) iter->data; for (int i = 0; i < n->draw_txt_buf.line_count; i++) { char *line = - draw_txt_get_line(&n->draw_txt_buf, i); + draw_txt_get_line(&n->draw_txt_buf, i+1); assert(line != NULL); width = MAX(width, textw(dc, line)); }