summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b9c1a33)
raw | patch | inline | side by side (parent: b9c1a33)
author | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Fri, 1 Jun 2007 17:59:25 +0000 (17:59 +0000) | ||
committer | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Fri, 1 Jun 2007 17:59:25 +0000 (17:59 +0000) |
src/rrd_graph.c | patch | blob | history |
diff --git a/src/rrd_graph.c b/src/rrd_graph.c
index 191404e2d0eab670b5f3fc093feb9c3890df38db..f9c7a1141db3eb958db373b617e57eaeaa67ba4f 100644 (file)
--- a/src/rrd_graph.c
+++ b/src/rrd_graph.c
** of the legend and the axis labels.
*/
- /* Determine where to place the legends onto the image.
- ** Set Ymain and adjust im->yorigin to match the space requirements.
- */
- if (leg_place(im, &Ymain) == -1)
- return -1;
+ if (im->extra_flags & NOLEGEND)
+ {
+ /* set dimensions correctly if using full size mode with no legend */
+ im->yorigin = im->yimg - im->text_prop[TEXT_PROP_AXIS].size * 2.5 - Yspacing;
+ Ymain = im->yorigin;
+ } else
+ {
+ /* Determine where to place the legends onto the image.
+ ** Set Ymain and adjust im->yorigin to match the space requirements.
+ */
+ if (leg_place(im, &Ymain) == -1)
+ return -1;
+ }
#ifdef WITH_PIECHART
/* if (im->yimg < Ypie) im->yimg = Ypie; * not sure what do about this */