[rrd-developers] Re: legend spacing problems

Tobias Oetiker oetiker at ee.ethz.ch
Fri Dec 13 07:54:37 MET 2002



Yesterday Carter Bullard wrote:

>
> Gentle people,
>    New to the list so sorry for any intrusion.  I was
> having problems trying to get the last line of legends
> to align when I had a lot of objects to graph.  My problem
> is solved by removing the "glue" spacing, which adds a
> variable fudge to the interlegend spacing on each line.
>
>    I'm not sure of the history of this glue spacing, is
> it possible to remove it, or put a switch around it?
> I'm suggesting removal, with the modification below.
>
> Any opinion is, of course, very welcome!
>
> Carter
>
>
> *** rrd_graph.c.orig    Thu Dec 12 19:50:10 2002
> --- rrd_graph.c Thu Dec 12 19:50:54 2002
> ***************
> *** 1719,1730 ****
>
>         if (prt_fctn != '\0'){
>             leg_x = border;
> -           if (leg_c >= 2 && prt_fctn == 'j') {
> -               glue = (im->xgif - fill - 2* border) / (leg_c-1);
> -               /* if (glue > 2 * SmallFont->w) glue = 0; */
> -           } else {
> -               glue = 0;
> -           }
>             if (prt_fctn =='c') leg_x =  (im->xgif - fill) / 2.0;
>             if (prt_fctn =='r') leg_x =  im->xgif - fill - border;

the glue is for justifying text ... so that it becomes left and
right aligned ... this is a feature ... when you want your legends
to be aligned differently break them by hand ... check the docs

tobi
>
> --- 1719,1724 ----
>
>
> --
> Unsubscribe mailto:rrd-developers-request at list.ee.ethz.ch?subject=unsubscribe
> Help        mailto:rrd-developers-request at list.ee.ethz.ch?subject=help
> Archive     http://www.ee.ethz.ch/~slist/rrd-developers
> WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi
>

-- 
 ______    __   _
/_  __/_  / /  (_) Oetiker, ETZ J97, ETH, CH-8092 Zurich, Switzerland
 / // _ \/ _ \/ /  System Manager Coach Time Lord Developer Designer
/_/ \.__/_.__/_/   http://people.ee.ethz.ch/~oetiker +41(0)1-632-5286

--
Unsubscribe mailto:rrd-developers-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-developers-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-developers
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the rrd-developers mailing list