Dear ROOT experts,
I am drawing a TH1D and I have defined x-labels with :
hist.GetXaxis().SetBinLabel(i_bin,my_string)
Then when I look at the plot, I see several labels overlapping and I would like to play with the angle of the label to avoid such overlaps.
After several tests of things found in the TAxis class or google, I am not able to modify the angle with
root [0] auto h = new TH1D("h","h",10,0.,1.)
(TH1D *) @0x7ffeef30a798
root [1] h->Draw()
Info in <TCanvas::MakeDefCanvas>: created default TCanvas with name c1
root [2] h->GetXaxis()->ChangeLabel(2,30,-1,-1,-1,-1,"Label with angle")
root [3] gPad->Update(); gPad->Modified();
if I use the ChangeLabel() alone I can rotate. But when both SetBinLabel() and ChangeLabel() are used, the ChangeLabel() is not applied.
I can close this ticket.
Thanks for your help.