CutG with WaitPrimitive() stalled


I’m trying to do a graphical cut in a TH2.
For that, I have tried to use the WaitPrimitive() function, wich seems to work, until I double click.
Then, the CutG complete the form, the cursor is not linked by a drawing line, but the function doesn’t return the hand. I can move the cut in the pad, but the program won’t proceed or I don’t have access to the prompt in interactive mode.
Here what I’m trying (in interractive mode):

root [0] TCutG * cutg = new TCutG()
root [1] TCanvas *c1 = new TCanvas(“c1”)
root [2] c1->WaitPrimitive(“cutg”,“CutG”);

Then, when I doubleclick for completing the cut, the form is completed, I can move it and access it’s function, but I still don’t have access to the prompt until I do ctrl-C…
I have tried with gPad, in a TH2 or TH1 without success.

I’m using root 5.28/00, compiled under opensuse 64bits.

What I’m doing wrong?


Maybe I missed something, but I have to specify the name of the CutG with “SetName()” when I rigth click on the cut.
I must change the default name (CUTG) and then I have access to the prompt again…
If I just use the default name, nothing happens. It have to be modified.
I think I can see why, but this is not coherent with the information provided in the “WaitPrimitive()” description: … tPrimitive
where there is no information about the CutG option and I was lead to believed that the “double-click” on the pad will return 0 because of the description of the WaitPrimitive() without option…

Anyway, maybe this should be clarified.
I’m still not 100% sure that I’m doing thing right there, but at least, it’s “working”.