Hi Christian, Your request could be implemented. However, I am quite relectant to implement more options of this type in TStyle. You can easily make a loop on all the histograms, eg loop on all objects of type histogram in the current directory; { TIter next(gDirectory->GetList()); TObject *obj; while ((obj=next())) { if (obj->InheritsFrom("TH1")) { TH1 *h = (TH1*)obj; h->GetXaxis()->SetTitle("E [keV]"); } } } Rene Brun On Thu, 29 Aug 2002 Christian.Doerr@mpi-hd.mpg.de wrote: > Hello everybody, > > I wonder whether is a way to set a standard title for the axis of every > histogram that is created in a session automatically, something like maybe > > gStyle->SetXaxisTitle("E [keV]"); > > It would be nice if I didn't have to call > > histo->GetXaxis()->SetTitle("E [keV]"); > > for every single histogram.... > > Maybe there is an elegant way to do that?? > Thanks for any suggestions! > > Christian > > > ----------------------------------------------------------- > Christian Doerr > Max-Planck-Institut fuer Kernphysik, Heidelberg > Bothe-Labor, room 232 phone: +49-6221-516-259 > email: C.Doerr@mpi-hd.mpg.de www.christiandoerr.de > ----------------------------------------------------------- > >
This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:51:08 MET