graph: use rounded graph connections
authorJens Axboe <axboe@kernel.dk>
Fri, 13 Apr 2012 12:23:17 +0000 (14:23 +0200)
committerJens Axboe <axboe@kernel.dk>
Fri, 13 Apr 2012 12:23:17 +0000 (14:23 +0200)
Signed-off-by: Jens Axboe <axboe@kernel.dk>
graph.c

diff --git a/graph.c b/graph.c
index 06cfb1a..7a35736 100644 (file)
--- a/graph.c
+++ b/graph.c
@@ -586,6 +586,8 @@ void line_graph_draw(struct graph *g, cairo_t *cr)
                goto skip_data;
 
        cairo_set_line_width(cr, 1.5);
+       cairo_set_line_join(cr, CAIRO_LINE_JOIN_ROUND);
+
        flist_for_each(lentry, &g->label_list) {
                i = flist_entry(lentry, struct graph_label, list);
                first = 1;
@@ -600,9 +602,8 @@ void line_graph_draw(struct graph *g, cairo_t *cr)
                        if (first) {
                                cairo_move_to(cr, tx, ty);
                                first = 0;
-                       } else {
+                       } else
                                cairo_line_to(cr, tx, ty);
-                       }
                }
                cairo_stroke(cr);
        }