Timothy Smith wrote: > > Hello Rooters, > > I am trying to create, store, redraw, etc. some cuts > in my ntuples. This works well enough in the Macros, and > in my compiled code I can make a TCutG via the editor, which > is called CUTG. But when I what to rename it such that > I can have more then one cut, I do not really know what > "CUTG" is. Does it belong to ?? > > The below is fine in Macros, but not in compiled. > > gROOT->SetEditorMode("CutG"); > CUTG->SetName("firstCut"); > Hi Tim, To access a TCutG object created with the graphics editor, do: TCutG *mycutg = (TCutG*)gPad->GetPrimitive("CUTG"); cutg->SetName("mycutg"); Note that the above method applies to all objects in a pad. I have added this info in the documentation of the class TCutG. Rene Brun
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:39 MET