Have a look at $ROOTSYS/test/guiviewer.cxx. Cheers, Fons. Thomas Bretz wrote: > > Hi Rooters, > > I derived a class from TEmbeddedCanvas. The embedded canvas is displayed > in a TGMainFrame. > > The TEmbeddedCanvas itself shows up (border, background, ...) but I'm > unable to draw something into it. Everything I tried to display > something in it (TArc, TH1F, ...) failed. What am I doing wrong? > > At the end I would like to have something like the following in its > constructor: > > ----------------- > GetCanvas()->cd(); > GetCanvas->Range(-100, -100, 100, 100); > > TArc *arc=new TArc(0, 0, 10); > arc->Draw(); > GetCanvas()->Modified(); > GetCanvas()->Update(); > ------------------ > > Regards, > Thomas. -- Org: CERN, European Laboratory for Particle Physics. Mail: 1211 Geneve 23, Switzerland E-Mail: Fons.Rademakers@cern.ch Phone: +41 22 7679248 WWW: http://root.cern.ch/~rdm/ Fax: +41 22 7677910
This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:47 MET