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

From: Faine, Valeri (fine@bnl.gov)
Date: Fri Apr 11 2003 - 20:05:48 MEST


Can you check whether you have the env variable "DISPLAY" set?
In my mind ROOT turns on the batch mode if this variable is undefined.

Please make sure you are not in the batch mode

Try to print out:

             gROOT->IsBatch()

  Valeri

> -----Original Message-----
> From: owner-roottalk@pcroot.cern.ch
[mailto:owner-roottalk@pcroot.cern.ch]
> On Behalf Of Jacek M. Holeczek
> Sent: Friday, April 11, 2003 1:13 PM
> To: RootTalk
> Subject: Re: [ROOT] canvas created but not drawn ...
> 
> Many thanks for help,
> 
> > 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.
> 
> I do not create "TApplication" (and I do not say "gROOT-
> >SetBatch(kTRUE)").
> Earlier today I had the idea to try "gROOT->SetBatch(kFALSE)" just
before
> making the new TCanvas, but it didn't help.
> 
> Can I somehow convince TROOT to draw my TCanvas without creating the
> "TApplication" ?
> 
> > About your point with c->Draw, you should not do:
> >   c->Draw(); c->Update();
> > but
> >   c->Modified(); c->Update();
> 
> This code is more than one year old (was running fine with 3.02, if I
> remember well). It redraws the canvas using new contents of histograms
> every 10 seconds. The sequence "c->Draw(); c->Update();" was found
> EXPERIMENTALLY by me. No other sequence was behaving properly
(including
> "c->Modified(); c->Update();"). It may well be that now I can change
it.
> Well, I could make some tests ... as soon as I get the canvas drawn.
> 
> Thanks in advance,
> Jacek.



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