Re: TPad address.

From: Rene Brun (Rene.Brun@cern.ch)
Date: Thu Apr 08 1999 - 15:56:10 MEST


Patrice (Pat) wrote:
> 
> Hello,
> 
> I have a simple request:
> For example:
> 
> TPad pad = new TPad("pad","",0.5,0.5,1.,1.);
> pad->Divide(2,3);
> pad->cd(4);
> // I am in pad_4
> // but how to get the pointer on this subpad without
> // using TROOT::FindObject method ?
> 
> // why not have:  TPad* subpad = pad->cd(4); !!!!!!!!!!!!!!
> 

Salut Patrice,
Use the global gPad (in TVirtualPad.h).
gPad always points to the current pad.

Rene Brun



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