Re: [ROOT] canvas created but not drawn ...

From: Rene Brun (Rene.Brun@cern.ch)
Date: Fri Apr 11 2003 - 18:30:55 MEST


Jacek,

I have the impression that you are running in batch mode. This is the
case when you do not define a TApplication object or if explictly
you call gROOT->SetBatch(kTRUE); Please check.

About your point with c->Draw, you should not do:
  c->Draw(); c->Update();
but
  c->Modified(); c->Update();

Rene Brun

"Jacek M. Holeczek" wrote:
> 
> > Did you draw something in the canvas?
> 
> The point is - there is NOTHING drawn, even the canvas itself.
> I mean, the "new TCanvas(...)" doesn't draw anything.
> And later the "c->Draw()" doesn't draw anything.
> 
> > Could you add the statement
> >   c->Saveas("mycancas.root");
> 
> Well, the "mycancas.root" looks perfectly fine.
> Is it possible that because I link my Geant4 application with root
> libraries (and not opposite) something important doesn't get initialized ?
> 
> > Note that the statement c->Draw() is redundant when called in the session
> > where the canvas has been created.
> 
> I need (from time to time) to "c->Draw(); c->Update();" in order to
> "refresh" the canvas.
> 
> Thanks in advance,
> Jacek.



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