Get Position of Axis


I’m working on an annotated graph/plot for a publication and I’ve run into a problem.

I need to draw primitive geometric objects which mark certain features of the plot. In order to do so I must provide the correct coordinates to those objects.

I’m looking for a way to get the (x1,y1), (x2,y1) coordinates (either in User or NDC coordinate system) of both the y-axis and x-axis object that is draw by the histogram which is part of the plot. I couldn’t find any method providing this information, maybe someone can help.


P.S. I’m using ROOT v 4.32.05.

Have a look into the subsections “The Coordinate Systems of a Pad” and “Converting between Coordinate Systems” in: ROOT User’s Guide -> Graphics and the Graphical User Interface -> Graphical Containers: Canvas and Pad

You can also try to play with: