15 TCanvas *c =
new TCanvas(
"c",
"A Simple Graph Example with Text",700,500);
19 auto gr =
new TGraph(n);
20 gr->SetTitle(
"A Simple Graph Example with Text");
21 gr->SetMarkerStyle(20);
22 auto ex =
new TExec(
"ex",
"drawtext();");
23 gr->GetListOfFunctions()->Add(ex);
26 for (Int_t i=0;i<n;i++) {
44 l.SetTextColor(kBlue);
46 auto g = (TGraph*)gPad->GetListOfPrimitives()->FindObject(
"Graph");
51 l.PaintText(x,y+0.2,Form(
"(%4.2f,%4.2f)",x,y));