I have noticed that if a SetRange, SetRangeUser or just a zoom with the mouse over a TH2 which has a TBox on it, the TBox range is not properly displayed. For instance if we make a SetRangeUser as in the example:
Only high level objects like TH1, TGraph, TF1 are clipped to the frame boundary, not low level classes like TLine, TBox, TText.
I suggest to use a TGraph instead of TBox if you need clipping.
No,we can easily clip any kind of polygon, but by principle we do not clip the low level objects to the frame boundary because you may want to draw these objects anywhere in the canvas.
As I said, if you want to clip a box, replace the TBox by a TGraph and it will be clipped at the frame boundary.