diff --git a/examples/cluster.c b/examples/cluster.c index a403af2..711da52 100644 --- a/examples/cluster.c +++ b/examples/cluster.c @@ -56,6 +56,12 @@ static void draw_tachometer(cairo_t *cr, double r) { int i; + cairo_select_font_face(cr, "Helvetica", + CAIRO_FONT_SLANT_NORMAL, + CAIRO_FONT_WEIGHT_NORMAL); + + cairo_set_font_size(cr, 24); + cairo_set_source_rgb(cr, 1, 1, 1); cairo_arc(cr, x, y, r, 0, 360); cairo_stroke(cr); @@ -130,15 +136,6 @@ static void draw_mfd(cairo_t *cr, } static void redraw(cairo_t *cr) { - /* - * Set up text - */ - cairo_select_font_face(cr, "Helvetica", - CAIRO_FONT_SLANT_NORMAL, - CAIRO_FONT_WEIGHT_NORMAL); - - cairo_set_font_size(cr, 24); - /* * Paint canvas black */