Re: TGaxis/TAxis : SetBinLabel()

From: Rene Brun <Rene.Brun_at_cern.ch>
Date: Mon, 4 Jan 2010 15:59:39 +0100


TGaxis is a pure graphics class that does not know anything about bins. TGaxis cannot inherit from TAxis because of libraries dependency problems (circularity).

Rene Brun

Marc Escalier wrote:
> thanks,
>
> i see
>
> so if somebody wish to do a TGaxis with label instead of TAxis, he can't.
> I see from the web some tricks which is to create a clone from a TAxis
> and then inheritate the TGaxis from the TAxis. A bit complex while to
> give the method to TGaxis could be useful, isn't it ?
>
>
> ================
> Olivier Couet a écrit :
>> Hi Marc,
>> The alphanumeric labels are stored in the TAxis class. Not in TGaxis.
>> Olivier
>>
>> -----Original Message-----
>> From: owner-roottalk_at_root.cern.ch [mailto:owner-roottalk_at_root.cern.ch]
>> On Behalf Of Marc Escalier
>> Sent: Monday, January 04, 2010 3:14 PM
>> To: roottalk_at_lxbuild091.cern.ch
>> Subject: [ROOT] TGaxis/TAxis : SetBinLabel()
>>
>> Hello,
>>
>> from a TH1 histogram, one can do
>> myhisto->GetXaxis()->SetBinLabel(NumberOfTheBin,"mylabel")
>> (which is a TAxis)
>>
>> but is there a way to use a SetBinLabel with a TGaxis instead of TAxis ?
>>
>> thanks
>>
>>
>
Received on Mon Jan 04 2010 - 15:59:45 CET

This archive was generated by hypermail 2.2.0 : Tue Jan 05 2010 - 05:50:02 CET