Error in saving the figure made by TArc (or TEllipse)

Hello

I would like to ask comments about the problem I am having now…

I made three circles with TArc (or TEllipse) method, which are concentric.
I set the fillStyle for each circle as Circle -> SetFillStyle(4000) to make them transparent
and it works well. The problem is when I save the figure(in eps or png or pdf),
the saved figure is different from the original figure. It seems like the fillStyle of the largest
circle is reset to be opaque and it hides other smaller circles as I am saving the figure.
I think it’s kind of bug. Please let me have some comments on this.
I am attaching my script as the appended section…

SC

{
TH2F *hh = new TH2F(“hh”,"",2,-10,10,2,-10,10);
NN = new TEllipse(0,0,1,1,0,360);
NN->SetLineColor(1);
NN->SetFillColor(1);
NN->SetFillStyle(3001);
NN1 = new TArc(0,0,2,0,360);
NN1->SetLineColor(2);
NN1->SetFillStyle(4000);
NN2 = new TArc(0,0,3,0,360);
NN2->SetLineColor(3);
NN2->SetFillStyle(4000);

TCanvas *can = new TCanvas(“can”,“can”,500,500);

gStyle->SetOptStat(0);
hh->Draw();
NN->Draw("");
NN1->Draw("");
NN2->Draw("");
}

1 Like

I tried your code, and for me the picture in .png format looks like the one in the ROOT window, but the pdf file has only the green circle.

I am attaching the .png file that I generated. Maybe if you open it and it looks fine, then we know it’s a problem with your system that generates the file. If you open it and it looks wrong, then it’s a problem with your image viewer program.

Jean-François