Re: TCanvas behaviour

From: Rene Brun (Rene.Brun@cern.ch)
Date: Thu Jan 16 1997 - 16:20:48 MET


OLSZEWSKI@vsk02.ifj.edu.pl wrote:
> 
>  Observation on SGI, Irix 5.3:
> 
>  One should only create TCanvas variables with "new" and not declare them
>  like: TCanvas can("ala");. In this later case the ROOT can not be reset
>  neither by .reset nor by gROOT.Reset() and executing same macro again
>  induces "segmentation violation" error.
> 
>  Trying other classes I do not observe this kind of behaviour. Is this
>  an error in ROOT?
> 
>  Andrzej.O.

You are right. If you look at the ROOT tutorials, we always
create TCanvas via new. This is necessary if you run to run
your macro many times in the same session.
Note that this also applies to TPad and TFile objects.
We still have to explain decently the general question of scoping
on our Web pages.
Thanks for the remark
Rene Brun



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:26:17 MET