From: oetiker Date: Sun, 8 May 2005 16:22:25 +0000 (+0000) Subject: * adjust spacing at the left border of the graph. use less white space X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=a940b995784c19fda0b46c756e2ef1f314d398d3;p=rrdtool-all.git * adjust spacing at the left border of the graph. use less white space * increasse minimal grid spacing and label spacing git-svn-id: svn://svn.oetiker.ch/rrdtool/branches/1.2@517 a5681a0c-68f1-0310-ab6d-d61299d08faa --- diff --git a/program/src/rrd_graph.c b/program/src/rrd_graph.c index f1e1fe7e..3e7b1afa 100644 --- a/program/src/rrd_graph.c +++ b/program/src/rrd_graph.c @@ -1589,7 +1589,7 @@ calc_horizontal_grid(image_desc_t *im) } for(i=0; i<4;i++) { - if (pixel * ylab[gridind].lfac[i] >= 2 * im->text_prop[TEXT_PROP_AXIS].size) { + if (pixel * ylab[gridind].lfac[i] >= 2.5 * im->text_prop[TEXT_PROP_AXIS].size) { im->ygrid_scale.labfact = ylab[gridind].lfac[i]; break; } @@ -1942,7 +1942,7 @@ grid_paint(image_desc_t *im) /* yaxis unit description */ gfx_new_text( im->canvas, - 12, (im->yorigin - im->ysize/2), + 10, (im->yorigin - im->ysize/2), im->graph_col[GRC_FONT], im->text_prop[TEXT_PROP_UNIT].font, im->text_prop[TEXT_PROP_UNIT].size, im->tabwidth, @@ -2151,7 +2151,7 @@ graph_size_location(image_desc_t *im, int elements } if (im->ylegend[0] != '\0' ) { - Xvertical = im->text_prop[TEXT_PROP_UNIT].size *1.6; + Xvertical = im->text_prop[TEXT_PROP_UNIT].size *2; } @@ -2180,7 +2180,7 @@ graph_size_location(image_desc_t *im, int elements im->text_prop[TEXT_PROP_AXIS].font, im->text_prop[TEXT_PROP_AXIS].size, im->tabwidth, - "0", 0) * im->unitslength + Xspacing; + "0", 0) * im->unitslength; } } @@ -2804,7 +2804,7 @@ rrd_graph_init(image_desc_t *im) im->minval = DNAN; im->maxval = DNAN; im->unitsexponent= 9999; - im->unitslength= 5; + im->unitslength= 6; im->symbol = ' '; im->viewfactor = 1.0; im->extra_flags= 0;