Not able to retrieve hist bin label created with ChangeLabel()

Dear ROOT experts,

I have an issue similar to Axis label disappears on saving.
However, I cannot get the bin label even exactly after I’ve set it with ChangeLabel().

The code is:

hist = TH1D("h1", "h1", 10, 0, 1)
h1->GetXaxis()->ChangeLabel(1, -1, -1, -1, -1, -1, "test")

Expected output: test
Actual output: (const char *) ""

The output of h1->Draw(), so the label is actually changing.

Is there a way to retrieve the bin labels set this way?

Thanks in advance,

ROOT Version: 6.24/06
Platform: lxplus

That does not work that way “ChangeLabel” is purely graphics and GetBinLabel does not see the new graphics label.

So if the label text was set with ChangeLabel() there’s no way to retrieve this text?

No, as I said it is purely graphics.