Re: [ROOT] Default canvas...

From: Rene Brun (Rene.Brun@cern.ch)
Date: Tue Jul 08 2003 - 19:07:09 MEST


Hi Zaldy,

I cannot reproduce this problem.
Could you send me a very short tar file with a test script?

Rene Brun

zaldy wrote:
> 
> Dear ROOT Users,
> 
> I am creating a canvas with the name myCanvas. In the class where this
> name belongs has the constructor similar to the default constructor.
> The structure of my class defination is as follows:
> 
> //-------------------------------------------
> //  Prototype
>     class A
>         {
>                 public:
>                         A();
>                         ~A();
> 
>                         void CreateCanvas();
>                         ..............
> 
>                 private:
>                         TCanvas * myCanvas;
>                         ....
>         };
> 
>   //source
>      A::A()
>      {;}
> 
>      A::~A()
>      {}
> 
>      void A::CreateCanvas()
>         {
>                 myCanvas = new TCanvas(...arguments_here...);
> 
>                 // a number of Pads are also defined inside this
>                 // user-function
>         }
> 
> //---------------------------------------------------
> 
> I noticed that when I create an instance
> of the class A in the main program (i,e, just like "A objectOf_ClassA;"),
> a canvas by the name "c1" always appears even
> though I did not call the method "CreateCanvas()".
> 
> Why is this so?
> How do we prevent (or switch off) this feature so that I can use my
> user defined TCanvas?
> 
> I use ROOT 3.04/02 December 2002.
> (I am using a compiled code, that make use of the command "make").
> 
> Thank you.
> 
> --------------------------------------------------------
>                    Zaldy A. Nawang
>                    PS Users Room 2
>                    Yon Gokan,
>                    E362, Neutrino Group,
>                    IPNS, KEK,
>                    Japan
> 
>                    e-mail: zaldy@neutrino.kek.jp
>                    Tel. No. : (81) 029864 - 5387
> --------------------------------------------------------



This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:13 MET