Echo object at mouse position.
Example of macro called when a pad is redrawn one must create a TExec object in the following way
gPad->AddExec(
"ex1",
".x exec1.C");
this macro prints the bin number and the bin content when one clicks on the histogram contour of any histogram in a pad
{
Error(
"exec1",
"gPad is null, you are not supposed to run this macro");
return;
}
int px =
gPad->GetEventX();
printf(
"event=%d, hist:%s, bin=%d, content=%f\n", event,
h->GetName(),
binx,
h->GetBinContent(
binx));
}
}
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
void Error(const char *location, const char *msgfmt,...)
Use this function in case an error occurred.
TH1 is the base class of all histogram classes in ROOT.
Mother of all ROOT objects.
- Authors
- Rene Brun, Sergey Linev
Definition in file exec1.C.