Different graphic behavior in batch mode

Hi,

I have a macro producing (and saving) some plots. The plots from batch mode (-b) look different from those from interactive mode when saved as .gif, .jpg and .tiff. Main differences are the size of the (tgraph) markers and the style of the lines. When saving as .ps however, the result is the same for both interactive and batch.

Here is a simple code that gives different results in batch mode:

   TGraph mygraf = TGraph(5);
   mygraf.SetPoint(0,1,1);
   mygraf.SetPoint(1,2,1);
   mygraf.SetPoint(2,3,1);
   mygraf.SetPoint(3,4,1);
   mygraf.SetPoint(4,5,1);

   mygraf.SetMarkerStyle(20);
   mygraf.SetMarkerColor(kBlue);
   mygraf.SetLineStyle(2);
   mygraf.SetLineWidth(3);

   TCanvas c = TCanvas("mycanvas", "mycanvas");

   mygraf.Draw("Alp");
   c.Print("mycanvas_b.gif", "gif");

If I run it in normal mode, I get a nice looking result (cf. attachement mycanvas.gif). If I run it in batch (-b) mode, it looks ugly (cf. attachment mycanvas_b.gif).

Are settings different in batch mode and interactive mode? If yes, is there a way to force the interactive settings?

Regards,

Jean-Francois




The main problem is the line style.
I’ll check.

The problem shows only if the line has a line width > 1.
I’ll continue to investigate.

This is now fixed in the svn trunk. The problem was with the horizontal dash lines having a
width greater than 1.

Thanks for the quick answer.

Regards,

Jean-Francois