RE: [ROOT] <TGX11TTF::SetColor>

From: Olivier Couet (couet@mail.cern.ch)
Date: Mon Sep 20 2004 - 11:54:16 MEST


Hi,

 I see what you mean. Actually I can reproduce if with the standard macro 
hsimple.C. After having executed it I change the histogram color, thanks 
to the editor, to one of the "other" colors. Then I save the result in 
both c1.C and c1.root. Executing c1.C works perfectly (the histogram 
color is the one I choose with "other"). But with c1.root I get the error 
you mentioned. I guess the colors are not yet properly saved in c1.root. 
May be you can use ".C" files instead of ".root" files until we fixed that ?

 Cheers,       Olivier


On Mon, 20 Sep 2004 pawan@rcf.rhic.bnl.gov wrote:

> Hi
> 
> Attached to this mail is a simple macro which creates
> 5 1D histograms.
> 
> After drawing them I fill them using the "editor".
> using the Fill option ("more color") & save the
> canvas to test.root (it is also attached).
> 
> Now when I open the test.root & draw the canvas
> I get these warning messages & the colors are not
> drawn :
> Warning in <TGX11TTF::SetColor>: color with index 229 not defined
> Warning in <TGX11TTF::SetColor>: color with index 229 not defined
> Warning in <TGX11TTF::SetColor>: color with index 230 not defined
> Warning in <TGX11TTF::SetColor>: color with index 230 not defined
> 
> But the histograms are drawn with white background
> regards
> Pawan
> 
> 
> 
> 
> 
> > Can you send a small example reproducing the problem ? (a small macro we
> > can use to reproduce the faulty .root file)
> >
> > Thanks,         O.Couet
> >
> > -----Original Message-----
> > From: owner-roottalk@pcroot.cern.ch
> > [mailto:owner-roottalk@pcroot.cern.ch] On Behalf Of
> > pawan@rcf.rhic.bnl.gov
> > Sent: Monday, September 20, 2004 10:12 AM
> > To: roottalk@pcroot.cern.ch
> > Subject: [ROOT] <TGX11TTF::SetColor>
> >
> >
> > Hi ROOTers
> >
> > I am drawing some set of histograms (1D) and using the color option
> > (more color) to color them. After that I save that canvas as a .root
> > file.
> >
> > Then when I open that root file like this
> >
> > <root> TFile f("filename.root","r")
> > <root> f.ls()
> > <root> TFile**  inc_minbias_allcent.root
> >        TFile*   inc_minbias_allcent.root
> >        KEY: TCanvas  c1;1    c1
> > <root> c1->Draw();
> >
> > when I draw them again  the it gave these error messages: Warning in
> > <TGX11TTF::SetColor>: color with index 235 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 233 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 229 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 230 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 232 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 236 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 233 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 229 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 230 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 232 not defined Warning in
> > <TGX11TTF::SetColor>: color with index 235 not defined
> >
> > and in the canvas I dont see those colors
> >
> > I am using Version   4.00/08 of root
> >
> > Any help??
> >
> > Regards
> > Pawan
> >
> >
> 

-- 
Org:    CERN - European Laboratory for Particle Physics.
Mail:   1211 Geneve 23 - Switzerland                     Mailbox: J25910      
E-Mail: Olivier.Couet@cern.ch                            Phone:   +41 22 7676522
WWW:    http://cern.ch/Olivier.Couet/                    Fax:     +41 22 7677155



This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 05:50:09 MET