ROOT logo

From $ROOTSYS/tutorials/graphics/pavetext.C

//Draw a pave text
//Author: Olivier Couet
{
   TCanvas *c = new TCanvas("c");
   TPaveText *pt = new TPaveText(.05,.1,.95,.8);

   pt->AddText("A TPaveText can contain severals line of text.");
   pt->AddText("They are added to the pave using the AddText method.");
   pt->AddLine(.0,.5,1.,.5);
   pt->AddText("Even complex TLatex formulas can be added:");
   pt->AddText("F(t) = #sum_{i=-#infty}^{#infty}A(i)cos#[]{#frac{i}{t+i}}");

   pt->Draw();
   return c;
} 
 pavetext.C:1
 pavetext.C:2
 pavetext.C:3
 pavetext.C:4
 pavetext.C:5
 pavetext.C:6
 pavetext.C:7
 pavetext.C:8
 pavetext.C:9
 pavetext.C:10
 pavetext.C:11
 pavetext.C:12
 pavetext.C:13
 pavetext.C:14
 pavetext.C:15
 pavetext.C:16
thumb