- if( !(im->extra_flags & NOLEGEND) ) {
- for(i=0;i<im->gdes_c;i++){
- if(im->gdes[i].legend[0] =='\0')
- continue;
-
- /* im->gdes[i].leg_y is the bottom of the legend */
- X0 = im->gdes[i].leg_x;
- Y0 = im->gdes[i].leg_y;
- /* Box needed? */
- if ( im->gdes[i].gf != GF_GPRINT
- && im->gdes[i].gf != GF_COMMENT) {
- int boxH, boxV;
-
- boxH = gfx_get_text_width(im->canvas, 0,
- im->text_prop[TEXT_PROP_AXIS].font,
- im->text_prop[TEXT_PROP_AXIS].size,
- im->tabwidth,"M", 0) * 1.25;
- boxV = boxH;
-
- node = gfx_new_area(im->canvas,
- X0,Y0-boxV,
- X0,Y0,
- X0+boxH,Y0,
- im->gdes[i].col);
- gfx_add_point ( node, X0+boxH, Y0-boxV );
- node = gfx_new_line(im->canvas,
- X0,Y0-boxV, X0,Y0,
- 1,0x000000FF);
- gfx_add_point(node,X0+boxH,Y0);
- gfx_add_point(node,X0+boxH,Y0-boxV);
- gfx_close_path(node);
- X0 += boxH / 1.25 * 2;
- }
- gfx_new_text ( im->canvas, X0, Y0,
+ if( !(im->extra_flags & NOLEGEND) & !(im->extra_flags & ONLY_GRAPH) ) {
+ for(i=0;i<im->gdes_c;i++){
+ if(im->gdes[i].legend[0] =='\0')
+ continue;
+
+ /* im->gdes[i].leg_y is the bottom of the legend */
+ X0 = im->gdes[i].leg_x;
+ Y0 = im->gdes[i].leg_y;
+ gfx_new_text ( im->canvas, X0, Y0,