397 fLimitFactorSize = 3;
416 fLimitFactorSize = 3;
442 ((
TLatex&)text).Copy(*
this);
477 ((
TLatex&)obj).fTabSize = 0;
521 const char *tab[] = {
"alpha",
"beta",
"chi",
"delta",
"varepsilon",
"phi",
"gamma",
"eta",
"iota",
"varphi",
"kappa",
"lambda",
522 "mu",
"nu",
"omicron",
"pi",
"theta",
"rho",
"sigma",
"tau",
"upsilon",
"varomega",
"omega",
"xi",
"psi",
"zeta",
523 "Alpha",
"Beta",
"Chi",
"Delta",
"Epsilon",
"Phi",
"Gamma",
"Eta",
"Iota",
"vartheta",
524 "Kappa",
"Lambda",
"Mu",
"Nu",
"Omicron",
"Pi",
"Theta",
"Rho",
"Sigma",
"Tau",
525 "Upsilon",
"varsigma",
"Omega",
"Xi",
"Psi",
"Zeta",
"varUpsilon",
"epsilon"};
527 const char *
tab2[] = {
"leq",
"/",
"infty",
"voidb",
"club",
"diamond",
"heart",
528 "spade",
"leftrightarrow",
"leftarrow",
"uparrow",
"rightarrow",
529 "downarrow",
"circ",
"pm",
"doublequote",
"geq",
"times",
"propto",
530 "partial",
"bullet",
"divide",
"neq",
"equiv",
"approx",
"3dots",
531 "cbar",
"topbar",
"downleftarrow",
"aleph",
"Jgothic",
"Rgothic",
"voidn",
532 "otimes",
"oplus",
"oslash",
"cap",
"cup",
"supset",
"supseteq",
533 "notsubset",
"subset",
"subseteq",
"in",
"notin",
"angle",
"nabla",
534 "oright",
"ocopyright",
"trademark",
"prod",
"surd",
"upoint",
"corner",
"wedge",
535 "vee",
"Leftrightarrow",
"Leftarrow",
"Uparrow",
"Rightarrow",
536 "Downarrow",
"diamond",
"LT",
"void1",
"copyright",
"void3",
"sum",
537 "arctop",
"lbar",
"arcbottom",
"topbar",
"void8",
"bottombar",
"arcbar",
538 "ltbar",
"AA",
"aa",
"void06",
"GT",
"int",
"forall",
"exists" };
540 const char *
tab3[] = {
"bar",
"vec",
"dot",
"hat",
"ddot",
"acute",
"grave",
"check",
"tilde",
"slash"};
544 Int_t nBlancDeb=0,nBlancFin=0,l_nBlancDeb=0,l_nBlancFin=0;
557 if (nBlancDeb==l_nBlancDeb && nBlancFin==l_nBlancFin) cont =
kFALSE;
560 if (t[nBlancDeb]==
'{' && t[length-nBlancFin-1]==
'}') {
563 for(i=nBlancDeb;i<length-nBlancFin;i++) {
564 if (t[i] ==
'{' && !(i>0 && t[i-1] ==
'@')) nBrackets++;
565 if (t[i] ==
'}' && t[i-1]!=
'@') nBrackets--;
566 if (nBrackets==0 && i<length-nBlancFin-2) {
582 l_nBlancDeb = nBlancDeb;
583 l_nBlancFin = nBlancFin;
588 length -= nBlancFin+nBlancDeb;
590 strncpy(text,t+nBlancDeb,length);
596 indiceSize = spec.
fSize;
599 specNewSize.
fSize = indiceSize;
608 Int_t opCurlyCurly = -1;
609 Int_t opSquareCurly = -1;
610 Int_t opCloseCurly = -2;
617 Int_t opSquareBracket = 0 ;
618 Int_t opBigCurly = 0 ;
621 Int_t abovePlace = 0 ;
629 Int_t opBackslash = 0;
630 Int_t opParallel = 0;
631 Int_t opSplitLine = -1;
643 case '\'' : quote1 = !quote1 ; break ;
644 case '"' : quote2 = !quote2 ; break ;
650 if (!(i>0 && text[i-1] ==
'@')) nBrackets++;
655 if (!(i>0 && text[i-1] ==
'@')) nBrackets--;
657 if (i<length-1)
if (text[i+1]==
'{' && opCurlyCurly==-1) opCurlyCurly=i;
659 if (text[i+1]!=
'{' && !(text[i+2]==
'{' && (text[i+1]==
'^' || text[i+1]==
'_'))
660 && opCloseCurly==-2) opCloseCurly=i;
662 else if (i<length-1) {
663 if (text[i+1]!=
'{' && opCloseCurly==-2) opCloseCurly=i;
665 else if (opCloseCurly==-2) opCloseCurly=i;
671 if (!(i>0 && text[i-1] ==
'@')) nCroch++;
676 if (!(i>0 && text[i-1] ==
'@')) nCroch--;
688 strncpy(buf,&text[i],2);
689 if (strncmp(buf,
"^{",2)==0) {
690 if (opPower==-1 && nBrackets==0 && nCroch==0) opPower=i;
693 strncpy(buf1,&text[i-4],4);
694 if (strncmp(buf1,
"#int",4)==0) {
696 if (i>4 && opCloseCurly==-2) opCloseCurly=i-5;
698 if (strncmp(buf1,
"#sum",4)==0) {
700 if (i>4 && opCloseCurly==-2) opCloseCurly=i-5;
704 if (strncmp(buf,
"_{",2)==0) {
705 if (opUnder==-1 && nBrackets==0 && nCroch==0) opUnder=i;
708 strncpy(buf2,&text[i-4],4);
709 if (strncmp(buf2,
"#int",4)==0) {
711 if (i>4 && opCloseCurly==-2) opCloseCurly=i-5;
713 if (strncmp(buf2,
"#sum",4)==0) {
715 if (i>4 && opCloseCurly==-2) opCloseCurly=i-5;
719 if (strncmp(buf,
"]{",2)==0)
720 if (opSquareCurly==-1 && nBrackets==0 && nCroch==0) opSquareCurly=i;
723 if (text[i]==
'\\' || (text[i]==
'#' && !opFound && nBrackets==0 && nCroch==0)) {
727 strncpy(buf,&text[i+1],10);
728 if (strncmp(buf,
"splitline{",10)==0) {
729 opSplitLine=i; opFound =
kTRUE;
730 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
736 strncpy(buf,&text[i+1],9);
737 if (!opBackslash && strncmp(buf,
"backslash",9)==0) {
738 opBackslash=1; opFound =
kTRUE;
739 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
745 strncpy(buf,&text[i+1],8);
746 if (!opParallel && strncmp(buf,
"parallel",8)==0) {
747 opParallel=1; opFound =
kTRUE;
748 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
754 strncpy(buf,&text[i+1],6);
755 if (strncmp(buf,
"lower[",6)==0 || strncmp(buf,
"lower{",6)==0) {
756 opLower=i; opFound =
kTRUE;
757 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
760 if (strncmp(buf,
"scale[",6)==0 || strncmp(buf,
"scale{",6)==0) {
761 opScale=i; opFound =
kTRUE;
762 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
765 if (strncmp(buf,
"color[",6)==0 || strncmp(buf,
"color{",6)==0) {
766 opColor=i; opFound =
kTRUE;
767 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
773 strncpy(buf,&text[i+1],5);
774 if (strncmp(buf,
"frac{",5)==0) {
775 opFrac=i; opFound =
kTRUE;
776 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
779 if (strncmp(buf,
"sqrt{",5)==0 || strncmp(buf,
"sqrt[",5)==0) {
780 opSqrt=i; opFound =
kTRUE;
781 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
784 if (strncmp(buf,
"font{",5)==0 || strncmp(buf,
"font[",5)==0) {
785 opFont=i; opFound =
kTRUE;
786 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
789 if (strncmp(buf,
"kern[",5)==0 || strncmp(buf,
"kern{",5)==0) {
790 opKern=i; opFound =
kTRUE;
791 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
794 if (!opMinus && strncmp(buf,
"minus",5)==0) {
795 opMinus=1; opFound =
kTRUE;
796 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
799 if (strncmp(buf,
"mbox[",5)==0 || strncmp(buf,
"mbox{",5)==0) {
800 opMbox=i; opFound =
kTRUE;
801 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
807 strncpy(buf,&text[i+1],4);
808 if (!opOdot && strncmp(buf,
"odot",4)==0) {
809 opOdot=1; opFound =
kTRUE;
810 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
813 if (!opHbar && strncmp(buf,
"hbar",4)==0) {
814 opHbar=1; opFound =
kTRUE;
815 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
818 if (!opPerp && strncmp(buf,
"perp",4)==0) {
819 opPerp=1; opFound =
kTRUE;
820 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
823 if (!opPlus && strncmp(buf,
"plus",4)==0) {
824 opPlus=1; opFound =
kTRUE;
825 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
831 strncpy(buf,&text[i+1],3);
833 if (strncmp(buf,
"[]{",3)==0) {
834 opSquareBracket=1; opFound =
kTRUE;
835 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
838 if (strncmp(buf,
"{}{",3)==0 ) {
839 opBigCurly=1; opFound =
kTRUE;
840 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
843 if (strncmp(buf,
"||{",3)==0) {
844 opAbs=1; opFound =
kTRUE;
845 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
848 if (strncmp(buf,
"(){",3)==0) {
849 opParen=1; opFound =
kTRUE;
850 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
853 if (!opBox && strncmp(buf,
"Box",3)==0) {
854 opBox=1; opFound =
kTRUE;
855 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
858 if (strncmp(buf,
"bf[",3)==0 || strncmp(buf,
"bf{",3)==0) {
859 opBf=i; opFound =
kTRUE;
860 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
863 if (strncmp(buf,
"it[",3)==0 || strncmp(buf,
"it{",3)==0) {
864 opIt=i; opFound =
kTRUE;
865 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
871 strncpy(buf,&text[i+1],2);
872 if (!opMp && strncmp(buf,
"mp",2)==0) {
873 opMp=1; opFound =
kTRUE;
874 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
879 if (!opFound &&
UInt_t(length)>i+strlen(tab[k])) {
880 if (strncmp(&text[i+1],tab[k],strlen(tab[k]))==0) {
883 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
888 if (!opFound &&
UInt_t(length)>i+strlen(tab3[k])) {
889 if (strncmp(&text[i+1],tab3[k],strlen(tab3[k]))==0) {
892 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
899 if ((opSpec==-1 || strlen(tab2[k])>lastsize) &&
UInt_t(length)>i+strlen(tab2[k])) {
900 if (strncmp(&text[i+1],tab2[k],strlen(tab2[k]))==0) {
901 lastsize = strlen(tab2[k]);
904 if (i>0 && opCloseCurly==-2) opCloseCurly=i-1;
917 if (opCloseCurly>-1 && opCloseCurly<length-1) {
919 fs1 =
Anal1(spec,text,opCloseCurly+1);
920 fs2 =
Anal1(spec,text+opCloseCurly+1,length-opCloseCurly-1);
924 Analyse(x+fs1.
Width(),
y,spec,text+opCloseCurly+1,length-opCloseCurly-1);
925 Analyse(x,y,spec,text,opCloseCurly+1);
930 else if (opPower>-1 && opUnder>-1) {
935 switch (abovePlace) {
937 prop = .8 ; propU = 1.75 ;
940 prop = .9 ; propU = 1.75 ;
949 if (min >= 2 && strncmp(&text[min-2],
"{}",2)==0) {
952 snprintf(&text[ltext-2],length-(ltext-2),
"I ") ;
955 fs1 =
Anal1(spec,text,ltext);
956 fs2 =
Anal1(specNewSize,text+min+1,
max-min-1);
968 if (opPower<opUnder) {
976 Analyse(x+addW,y+addH1,specNewSize,text+min+1,
max-min-1);
978 Double_t addW1, addW2, addH1, addH2;
980 pos = (m-fs1.
Width())/2;
981 if (opPower<opUnder) {
983 addW1 = (m-fs2.
Width())/2;
985 addW2 = (m-fs3.
Width())/2;
988 addW1 = (m-fs2.
Width())/2;
990 addW2 = (m-fs3.
Width())/2;
993 Analyse(x+addW2,y+addH2,specNewSize,text+
max+1,length-
max-1);
994 Analyse(x+addW1,y+addH1,specNewSize,text+min+1,
max-min-1);
997 if (min >= 2 && strncmp(&text[min-2],
"{}",2)==0) {
998 snprintf(&text[min-2],length-(min-2),
" ") ;
999 Analyse(x+pos,y,spec,text,min-1);
1001 Analyse(x+pos,y,spec,text,min);
1006 if (opPower<opUnder) {
1016 if (opPower<opUnder) {
1025 else if (opPower>-1) {
1028 switch (abovePlace) {
1030 prop = 1.75 ; break ;
1032 prop = 1.75; break ;
1036 Int_t ltext = opPower ;
1037 if (ltext >= 2 && strncmp(&text[ltext-2],
"{}",2)==0) {
1040 snprintf(&text[ltext-2],length-(ltext-2),
"I ") ;
1043 fs1 =
Anal1(spec,text,ltext);
1044 fs2 =
Anal1(specNewSize,text+opPower+1,length-opPower-1);
1053 if (over <= 0) over = 1.5*fs2.
Over();
1062 Analyse(x+pos2,y-fs1.
Over()*prop-fs2.
Under(),specNewSize,text+opPower+1,length-opPower-1);
1064 if (opPower >= 2 && strncmp(&text[opPower-2],
"{}",2)==0) {
1065 snprintf(&text[opPower-2],length-(opPower-2),
" ") ;
1066 Analyse(x+pos,y,spec,text,opPower-1);
1068 Analyse(x+pos,y,spec,text,opPower);
1079 else if (opUnder>-1) {
1085 Int_t ltext = opUnder ;
1086 if (ltext >= 2 && strncmp(&text[ltext-2],
"{}",2)==0) {
1089 snprintf(&text[ltext-2],length-(ltext-2),
"I ") ;
1092 fs1 =
Anal1(spec,text,ltext);
1093 fs2 =
Anal1(specNewSize,text+opUnder+1,length-opUnder-1);
1101 Analyse(x+fs1.
Width()+xfpos,y+fs1.
Under()+fs2.
Over()*fpos,specNewSize,text+opUnder+1,length-opUnder-1);
1109 Analyse(x+pos2,y+fs1.
Under()*prop+fs2.
Over(),specNewSize,text+opUnder+1,length-opUnder-1);
1111 if (opUnder >= 2 && strncmp(&text[opUnder-2],
"{}",2)==0) {
1112 snprintf(&text[opUnder-2],length-(opUnder-2),
" ") ;
1113 Analyse(x+pos,y,spec,text,opUnder-1);
1115 Analyse(x+pos,y,spec,text,opUnder);
1127 fs1 =
Anal1(spec,text+4,length-4);
1129 fs1 =
Analyse(x+square,y,spec,text+4,length-4);
1145 fs1 =
Anal1(spec,text+5,length-5);
1147 fs1 =
Analyse(x+1.3*square,y,spec,text+5,length-5);
1159 fs1 =
Anal1(spec,text+5,length-5);
1161 fs1 =
Analyse(x+square,y,spec,text+5,length-5);
1174 DrawLine(x,y-0.8*square,x+0.75*square,y-square,spec);
1181 fs1 =
Anal1(spec,text+6,length-6);
1183 fs1 =
Analyse(x+square,y,spec,text+6,length-6);
1202 fs1 =
Anal1(spec,text+5,length-5);
1204 fs1 =
Analyse(x+square,y,spec,text+5,length-5);
1223 fs1 =
Anal1(spec,text+3,length-3);
1225 fs1 =
Analyse(x+square,y,spec,text+3,length-3);
1244 fs1 =
Anal1(spec,text+5,length-5);
1246 fs1 =
Analyse(x+0.5*square,y,spec,text+5,length-5);
1257 else if (opBackslash) {
1260 fs1 =
Anal1(spec,text+10,length-10);
1262 fs1 =
Analyse(x+square,y,spec,text+10,length-10);
1278 else if (opParallel) {
1281 fs1 =
Anal1(spec,text+9,length-9);
1283 fs1 =
Analyse(x+0.5*square,y,spec,text+9,length-9);
1293 else if (opGreek>-1) {
1296 char letter = 97 + opGreek;
1298 if (opGreek>25) letter -= 58;
1299 if (opGreek == 52) letter =
'\241';
1300 if (opGreek == 53) letter =
'\316';
1302 fs1 =
Anal1(newSpec,&letter,1);
1303 fs2 =
Anal1(spec,text+strlen(tab[opGreek])+1,length-strlen(tab[opGreek])-1);
1307 Analyse(x+fs1.
Width(),
y,spec,text+strlen(tab[opGreek])+1,length-strlen(tab[opGreek])-1);
1308 Analyse(x,y-yoffset,newSpec,&letter,1);
1314 else if (opSpec>-1) {
1317 char letter =
'\243' + opSpec;
1318 if(opSpec == 75 || opSpec == 76) {
1320 if (opSpec == 75) letter =
'\305';
1321 if (opSpec == 76) letter =
'\345';
1323 if(opSpec == 80 || opSpec == 81) {
1324 if (opSpec == 80) letter =
'\042';
1325 if (opSpec == 81) letter =
'\044';
1333 }
else if (opSpec==79) {
1337 fs1 =
Anal1(newSpec,&letter,1);
1338 if (opSpec == 79 || opSpec == 66)
1341 fs2 =
Anal1(spec,text+strlen(tab2[opSpec])+1,length-strlen(tab2[opSpec])-1);
1345 Analyse(x+fs1.
Width(),
y,spec,text+strlen(tab2[opSpec])+1,length-strlen(tab2[opSpec])-1);
1346 if (opSpec!=66 && opSpec!=79)
1347 Analyse(x,y,newSpec,&letter,1);
1354 else if (opAbove>-1) {
1356 fs1 =
Anal1(spec,text+strlen(tab3[opAbove])+1,length-strlen(tab3[opAbove])-1);
1360 Analyse(x,y,spec,text+strlen(tab3[opAbove])+1,length-strlen(tab3[opAbove])-1);
1366 ypos = y-fs1.
Over()-sub ;
1371 y0 = y-sub-fs1.
Over() ;
1373 x1 = x+fs1.
Width() ;
1379 x1 = x+fs1.
Width()/2-3*sub/4 ;
1380 x2 = x+fs1.
Width()/2+3*sub/4 ;
1381 y1 = y-sub-fs1.
Over() ;
1385 x2 = x+fs1.
Width()/2 ;
1388 x1 = x2-fs1.
Width()/3 ;
1389 x3 = x2+fs1.
Width()/3 ;
1394 x1 = x+fs1.
Width()/2-9*sub/4 ;
1395 x2 = x+fs1.
Width()/2-3*sub/4 ;
1396 x3 = x+fs1.
Width()/2+9*sub/4 ;
1397 x4 = x+fs1.
Width()/2+3*sub/4 ;
1398 y1 = y-sub-fs1.
Over() ;
1403 x1 = x+fs1.
Width()/2;
1404 y1 = y +sub -fs1.
Over() ;
1410 x1 = x+fs1.
Width()/2-sub;
1411 y1 = y-sub-fs1.
Over() ;
1417 x1 = x+fs1.
Width()/2 ;
1420 y1 = y-sub-fs1.
Over() ;
1425 x2 = x+fs1.
Width()/2 ;
1426 y2 = y -fs1.
Over() ;
1433 if (
gVirtualX->InheritsFrom(
"TGCocoa")) y2 -= 3*sub;
1438 Double_t xx =
gPad->AbsPixeltoX(
Int_t((x2-xOrigin)*cosang+(y2-yOrigin)*sinang+xOrigin));
1439 Double_t yy =
gPad->AbsPixeltoY(
Int_t((x2-xOrigin)*-sinang+(y2-yOrigin)*cosang+yOrigin));
1450 xx =
gPad->AbsPixeltoX(
Int_t((x2-xOrigin)*cosang+(y22-yOrigin)*sinang+xOrigin));
1451 yy =
gPad->AbsPixeltoY(
Int_t((x2-xOrigin)*-sinang+(y22-yOrigin)*cosang+yOrigin));
1458 x1 = x + 0.8*fs1.
Width();
1459 y1 = y -fs1.
Over() ;
1460 x2 = x + 0.3*fs1.
Width();
1461 y2 = y1 + 1.2*fs1.
Height();
1467 if (opAbove==1) div=4;
1470 else if (opSquareBracket) {
1474 fs1 =
Anal1(spec,text+3,length-3);
1478 Analyse(x+l2+l,y,spec,text+3,length-3);
1490 Double_t radius2,radius1 , dw, l2 = l/2 ;
1493 fs1 =
Anal1(spec,text+3,length-3);
1496 radius1 = radius2 * 2 / 3;
1501 radius1 = radius2 * 2 / 3;
1508 Analyse(x+3*l2+dw,y,spec,text+3,length-3);
1517 fs1 =
Anal1(spec,text+3,length-3);
1521 Analyse(x+l2+l,y,spec,text+3,length-3);
1527 else if (opBigCurly) {
1533 fs1 =
Anal1(spec,text+3,length-3);
1544 Analyse(x+l+ltip+l2,y,spec,text+3,length-3);
1547 DrawLine(x+l2+ltip,y-fs1.
Over(),x+l2+ltip,y2-ltip,spec);
1553 DrawLine(x+l2,y2,x+l2+ltip,y2-ltip,spec);
1554 DrawLine(x+l2,y2,x+l2+ltip,y2+ltip,spec);
1569 else if (opFrac>-1) {
1570 if (opCurlyCurly==-1) {
1572 fError =
"Missing denominator for #frac";
1577 fs1 =
Anal1(spec,text+opFrac+6,opCurlyCurly-opFrac-6);
1578 fs2 =
Anal1(spec,text+opCurlyCurly+2,length-opCurlyCurly-3);
1592 Analyse(x+addW2,y+fs2.
Over()-height,spec,text+opCurlyCurly+2,length-opCurlyCurly-3);
1593 Analyse(x+addW1,y-fs1.
Under()-3*height,spec,text+opFrac+6,opCurlyCurly-opFrac-6);
1601 else if (opSplitLine>-1) {
1602 if (opCurlyCurly==-1) {
1604 fError =
"Missing second line for #splitline";
1609 fs1 =
Anal1(spec,text+opSplitLine+11,opCurlyCurly-opSplitLine-11);
1610 fs2 =
Anal1(spec,text+opCurlyCurly+2,length-opCurlyCurly-3);
1616 Analyse(x,y+fs2.
Over()-height,spec,text+opCurlyCurly+2,length-opCurlyCurly-3);
1617 Analyse(x,y-fs1.
Under()-3*height,spec,text+opSplitLine+11,opCurlyCurly-opSplitLine-11);
1623 else if (opSqrt>-1) {
1625 if (opSquareCurly>-1) {
1627 fs1 =
Anal1(specNewSize,text+opSqrt+6,opSquareCurly-opSqrt-6);
1628 fs2 =
Anal1(spec,text+opSquareCurly+1,length-opSquareCurly-1);
1634 fs1 =
Anal1(spec,text+opSqrt+5,length-opSqrt-5);
1639 if (opSquareCurly>-1) {
1647 Analyse(x+pas2,y,spec,text+opSquareCurly+1,length-opSquareCurly-1);
1648 Analyse(x,y-fs2.
Over()-fs1.
Under(),specNewSize,text+opSqrt+6,opSquareCurly-opSqrt-6);
1668 DrawLine(x1-2*dx,y1,x1-dx,y2,spec);
1676 else if (opColor>-1) {
1677 if (opSquareCurly==-1) {
1679 fError =
"Missing color number. Syntax is #color[(Int_t)nb]{ ... }";
1684 strncpy(nb,text+opColor+7,opSquareCurly-opColor-7);
1685 nb[opSquareCurly-opColor-7] = 0;
1686 if (sscanf(nb,
"%d",&newSpec.
fColor) < 1) {
1689 fError =
"Invalid color number. Syntax is #color[(Int_t)nb]{ ... }";
1694 result =
Anal1(newSpec,text+opSquareCurly+1,length-opSquareCurly-1);
1696 Analyse(x,y,newSpec,text+opSquareCurly+1,length-opSquareCurly-1);
1699 else if (opFont>-1) {
1700 if (opSquareCurly==-1) {
1702 fError =
"Missing font number. Syntax is #font[nb]{ ... }";
1707 strncpy(nb,text+opFont+6,opSquareCurly-opFont-6);
1708 nb[opSquareCurly-opFont-6] = 0;
1709 if (sscanf(nb,
"%d",&newSpec.
fFont) < 1) {
1712 fError =
"Invalid font number. Syntax is #font[(Int_t)nb]{ ... }";
1717 result =
Anal1(newSpec,text+opSquareCurly+1,length-opSquareCurly-1);
1719 Analyse(x,y,newSpec,text+opSquareCurly+1,length-opSquareCurly-1);
1722 else if (opKern>-1) {
1723 if (opSquareCurly==-1) {
1725 fError =
"Missing horizontal shift number. Syntax is #kern[dx]{ ... }";
1729 strncpy(dxc,text+opKern+6,opSquareCurly-opKern-6);
1730 dxc[opSquareCurly-opKern-6] = 0;
1732 if (sscanf(dxc,
"%f",&dx) < 1) {
1735 fError =
"Invalid horizontal shift number. Syntax is #kern[(Float_t)dx]{ ... }";
1740 fs1 =
Anal1(spec,text+opSquareCurly+1,length-opSquareCurly-1);
1747 Analyse(x + ddx,y,spec,text+opSquareCurly+1,length-opSquareCurly-1);
1750 else if (opLower>-1) {
1751 if (opSquareCurly==-1) {
1753 fError =
"Missing vertical shift number. Syntax is #lower[dy]{ ... }";
1757 strncpy(dyc,text+opLower+7,opSquareCurly-opLower-7);
1758 dyc[opSquareCurly-opLower-7] = 0;
1760 if (sscanf(dyc,
"%f",&dy) < 1) {
1763 fError =
"Invalid vertical shift number. Syntax is #lower[(Float_t)dy]{ ... }";
1768 fs1 =
Anal1(spec,text+opSquareCurly+1,length-opSquareCurly-1);
1775 Analyse(x,y + ddy,spec,text+opSquareCurly+1,length-opSquareCurly-1);
1778 else if (opScale>-1) {
1779 if (opSquareCurly==-1) {
1781 fError =
"Missing scale factor. Syntax is #scale[(Double_t)nb]{ ... }";
1786 strncpy(nb,text+opScale+7,opSquareCurly-opScale-7);
1787 nb[opSquareCurly-opScale-7] = 0;
1788 if (sscanf(nb,
"%lf",&newSpec.
fSize) < 1) {
1791 fError =
"Invalid scale factor. Syntax is #factor[(Double_t)nb]{ ... }";
1797 result =
Anal1(newSpec,text+opSquareCurly+1,length-opSquareCurly-1);
1799 Analyse(x,y,newSpec,text+opSquareCurly+1,length-opSquareCurly-1);
1804 Int_t lut[] = {3, 13, 1, 6, 7, 4, 5, 10, 11, 8, 9, 12, 2, 14, 15};
1806 if ((fontId >= 1) && (fontId <= (
Int_t)(
sizeof(lut)/
sizeof(lut[0])))) fontId = lut[fontId-1];
1807 newSpec.
fFont = fontId*10 + newSpec.
fFont%10;
1809 fs1 =
Anal1(newSpec,text+3,length-3);
1813 Analyse(x,y,newSpec,text+3,length-3);
1817 else if (opMbox>-1) {
1820 fs1 =
Anal1(newSpec,text+5,length-5);
1824 Analyse(x,y,newSpec,text+5,length-5);
1830 Int_t lut[] = {13, 3, 2, 5, 4, 7, 6, 9, 8, 11, 10, 15, 1, 14, 12};
1832 if ((fontId >= 1) && (fontId <= (
Int_t)(
sizeof(lut)/
sizeof(lut[0])))) fontId = lut[fontId-1];
1833 newSpec.
fFont = fontId*10 + newSpec.
fFont%10;
1836 fs1 =
Anal1(newSpec,text+3,length-3);
1840 Analyse(x,y,newSpec,text+3,length-3);
1854 Int_t leng = strlen(text) ;
1856 quote1 = quote2 =
kFALSE ;
1858 for (i=0 ; i<leng ; i++) {
1860 case '\'' : quote1 = !quote1 ; break ;
1861 case '"' : quote2 = !quote2 ; break ;
1864 if (text[i] ==
'@') {
1866 if ( *(p+1) ==
'{' || *(p+1) ==
'}' || *(p+1) ==
'[' || *(p+1) ==
']') {
1883 gPad->PaintText(xx,yy,text);
1933 Double_t xx =
gPad->AbsPixeltoX(
Int_t((x1-xOrigin)*cosang+(y1-yOrigin)*sinang+xOrigin));
1934 Double_t yy =
gPad->AbsPixeltoY(
Int_t((x1-xOrigin)*-sinang+(y1-yOrigin)*cosang+yOrigin));
1936 Double_t xx2 =
gPad->AbsPixeltoX(
Int_t((x2-xOrigin)*cosang+(y2-yOrigin)*sinang+xOrigin));
1937 Double_t yy2 =
gPad->AbsPixeltoY(
Int_t((x2-xOrigin)*-sinang+(y2-yOrigin)*cosang+yOrigin));
1941 gPad->PaintLine(xx,yy,xx2,yy2);
1955 const Int_t np = 40;
1963 for (
Int_t i=0;i<=np;i++) {
1967 x[i] =
gPad->AbsPixeltoX(
Int_t( dx*cosang+ dy*sinang +xOrigin));
1968 y[i] =
gPad->AbsPixeltoY(
Int_t(-dx*sinang+ dy*cosang +yOrigin));
1970 gPad->PaintPolyLine(np+1,x,y);
1986 const Int_t np = 40;
1994 for (
Int_t i=0;i<=np;i++) {
1998 x[i] =
gPad->AbsPixeltoX(
Int_t( dx*cosang+dy*sinang +xOrigin));
1999 y[i] =
gPad->AbsPixeltoY(
Int_t(-dx*sinang+dy*cosang +yOrigin));
2001 gPad->PaintPolyLine(np+1,x,y);
2038 if (t.Index(
"#")>=0 || t.Index(
"^")>=0 || t.Index(
"\\")>=0) {
2039 t.ReplaceAll(
"#LT",
"\\langle");
2040 t.ReplaceAll(
"#GT",
"\\rangle");
2041 t.ReplaceAll(
"#club",
"\\clubsuit");
2042 t.ReplaceAll(
"#spade",
"\\spadesuit");
2043 t.ReplaceAll(
"#heart",
"\\heartsuit");
2044 t.ReplaceAll(
"#diamond",
"\\diamondsuit");
2045 t.ReplaceAll(
"#voidn",
"\\wp");
2046 t.ReplaceAll(
"#voidb",
"f");
2047 t.ReplaceAll(
"#ocopyright",
"\\copyright");
2048 t.ReplaceAll(
"#trademark",
"TM");
2049 t.ReplaceAll(
"#void3",
"TM");
2050 t.ReplaceAll(
"#oright",
"R");
2051 t.ReplaceAll(
"#void1",
"R");
2052 t.ReplaceAll(
"#3dots",
"\\ldots");
2053 t.ReplaceAll(
"#lbar",
"\\mid");
2054 t.ReplaceAll(
"#void8",
"\\mid");
2055 t.ReplaceAll(
"#divide",
"\\div");
2056 t.ReplaceAll(
"#Jgothic",
"\\Im");
2057 t.ReplaceAll(
"#Rgothic",
"\\Re");
2058 t.ReplaceAll(
"#doublequote",
"\"");
2059 t.ReplaceAll(
"#plus",
"+");
2060 t.ReplaceAll(
"#minus",
"-");
2061 t.ReplaceAll(
"#/",
"/");
2062 t.ReplaceAll(
"#upoint",
".");
2063 t.ReplaceAll(
"#aa",
"\\mbox{\\aa}");
2064 t.ReplaceAll(
"#AA",
"\\mbox{\\AA}");
2066 t.ReplaceAll(
"#omicron",
"o");
2067 t.ReplaceAll(
"#Alpha",
"A");
2068 t.ReplaceAll(
"#Beta",
"B");
2069 t.ReplaceAll(
"#Epsilon",
"E");
2070 t.ReplaceAll(
"#Zeta",
"Z");
2071 t.ReplaceAll(
"#Eta",
"H");
2072 t.ReplaceAll(
"#Iota",
"I");
2073 t.ReplaceAll(
"#Kappa",
"K");
2074 t.ReplaceAll(
"#Mu",
"M");
2075 t.ReplaceAll(
"#Nu",
"N");
2076 t.ReplaceAll(
"#Omicron",
"O");
2077 t.ReplaceAll(
"#Rho",
"P");
2078 t.ReplaceAll(
"#Tau",
"T");
2079 t.ReplaceAll(
"#Chi",
"X");
2080 t.ReplaceAll(
"#varomega",
"\\varpi");
2082 t.ReplaceAll(
"#varUpsilon",
"?");
2083 t.ReplaceAll(
"#corner",
"?");
2084 t.ReplaceAll(
"#ltbar",
"?");
2085 t.ReplaceAll(
"#bottombar",
"?");
2086 t.ReplaceAll(
"#notsubset",
"?");
2087 t.ReplaceAll(
"#arcbottom",
"?");
2088 t.ReplaceAll(
"#cbar",
"?");
2089 t.ReplaceAll(
"#arctop",
"?");
2090 t.ReplaceAll(
"#topbar",
"?");
2091 t.ReplaceAll(
"#arcbar",
"?");
2092 t.ReplaceAll(
"#downleftarrow",
"?");
2093 t.ReplaceAll(
"#splitline",
"\\genfrac{}{}{0pt}{}");
2095 t.ReplaceAll(
"#",
"\\");
2096 t.ReplaceAll(
"%",
"\\%");
2106 gPad->SetBatch(saveb);
2121 if( newText.
Length() == 0)
return 0;
2126 std::cout<<
"\n*ERROR<TLatex>: "<<
fError<<std::endl;
2127 std::cout<<
"==> "<<text1<<std::endl;
2136 gPad->PaintText(x,y,text1);
2141 if (strstr(text1,
"\\")) {
2168 x =
gPad->XtoAbsPixel(x);
2169 y =
gPad->YtoAbsPixel(y);
2189 std::cout<<
"*ERROR<TLatex>: "<<
fError<<std::endl;
2190 std::cout<<
"==> "<<text<<std::endl;
2193 newSpec.
fSize = size;
2196 case 0: y -= fs.
Under() ;
break;
2198 case 2: y += fs.
Height()*0.5-fs.
Under(); y++;
break;
2199 case 3: y += fs.
Over() ;
break;
2202 case 2: x -= fs.
Width()/2 ;
break;
2203 case 3: x -= fs.
Width() ;
break;
2205 Analyse(x,y,newSpec,text,length);
2216 if (
fError != 0)
return 0;
2225 const Char_t *kWord1[] = {
"{}^{",
"{}_{",
"^{",
"_{",
"#scale{",
"#color{",
"#font{",
"#sqrt{",
"#[]{",
"#{}{",
"#||{",
2226 "#bar{",
"#vec{",
"#dot{",
"#hat{",
"#ddot{",
"#acute{",
"#grave{",
"#check{",
"#tilde{",
"#slash{",
"#bf{",
"#it{",
"#mbox{",
2227 "\\scale{",
"\\color{",
"\\font{",
"\\sqrt{",
"\\[]{",
"\\{}{",
"\\||{",
"#(){",
"\\(){",
2228 "\\bar{",
"\\vec{",
"\\dot{",
"\\hat{",
"\\ddot{",
"\\acute{",
"\\grave{",
"\\check{",
"\\bf{",
"\\it{",
"\\mbox{"};
2229 const Char_t *kWord2[] = {
"#scale[",
"#color[",
"#font[",
"#sqrt[",
"#kern[",
"#lower[",
"\\scale[",
"\\color[",
"\\font[",
"\\sqrt[",
"\\kern[",
"\\lower["};
2230 const Char_t *kWord3[] = {
"#frac{",
"\\frac{",
"#splitline{",
"\\splitline{"};
2231 const Char_t *kLeft1[] = {
"#left[",
"\\left[",
"#left{",
"\\left{",
"#left|",
"\\left|",
"#left(",
"\\left("};
2232 const Char_t *kLeft2[] = {
"#[]{",
"#[]{",
"#{}{",
"#{}{",
"#||{",
"#||{",
"#(){",
"#(){"};
2233 const Char_t *kRight[] = {
"#right]",
"\\right]",
"#right}",
"\\right}",
"#right|",
"\\right|",
"#right)",
"\\right)"};
2234 const Int_t lkWord1[] = {4,4,2,2,7,7,6,6,4,4,4,5,5,5,5,6,7,7,7,7,7,4,4,6,7,7,6,6,4,4,4,4,4,5,5,5,5,6,7,7,7,4,4,6};
2235 const Int_t lkWord2[] = {7,7,6,6,6,7,7,7,6,6,6,7} ;
2236 const Int_t lkWord3[] = {6,6,11,11} ;
2237 Int_t nkWord1 = 44, nkWord2 = 12, nkWord3 = 4;
2239 Int_t nLeft1 , nRight , nOfLeft, nOfRight;
2243 nLeft1 = nRight = 8 ;
2244 nOfLeft = nOfRight = 0 ;
2246 Char_t buf[11] ;
for (i=0;i<11;i++) buf[i]=0;
2251 Int_t nOfCurlyBracket, nOfKW1, nOfKW2, nOfKW3, nOfSquareCurly, nOfCurlyCurly ;
2252 Int_t nOfExtraCurly = 0 , nOfExtraSquare = 0;
2253 Int_t nOfSquareBracket = 0 ;
2260 while (i < length) {
2263 strncpy(buf,&text[i],
TMath::Min(7,length-i));
2265 for (k = 0 ; k < nLeft1 ; k++) {
2266 if (strncmp(buf,kLeft1[k],lLeft1)==0) {
2275 for(k=0;k<nRight;k++) {
2276 if (strncmp(buf,kRight[k],lRight)==0) {
2285 if (nOfLeft != nOfRight) {
2286 printf(
" nOfLeft = %d, nOfRight = %d\n",nOfLeft,nOfRight) ;
2288 fError =
"Operators \"#left\" and \"#right\" don't match !" ;
2292 for (k = 0 ; k < nLeft1 ; k++) {
2293 text.
ReplaceAll(kLeft1[k],lLeft1,kLeft2[k],lLeft2) ;
2295 for (k = 0 ; k < nRight ; k++) {
2300 i = nOfCurlyBracket = nOfKW1 = nOfKW2 = nOfKW3 = nOfSquareCurly = nOfCurlyCurly =0 ;
2303 case '"' : quote1 = !quote1 ; break ;
2304 case '\'': quote2 = !quote2 ; break ;
2308 strncpy(buf,&text[i],
TMath::Min(11,length-i));
2311 for(k=0;k<nkWord1;k++) {
2312 if (strncmp(buf,kWord1[k],lkWord1[k])==0) {
2322 for(k=0;k<nkWord2;k++) {
2323 if (strncmp(buf,kWord2[k],lkWord2[k])==0) {
2333 for(k=0;k<nkWord3;k++) {
2334 if (strncmp(buf,kWord3[k],lkWord3[k])==0) {
2344 if (strncmp(buf,
"}{",2) == 0 && opFrac) {
2349 else if (strncmp(buf,
"]{",2) == 0 && nOfSquareBracket) {
2353 nOfSquareBracket-- ;
2355 else if (strncmp(buf,
"@{",2) == 0 || strncmp(buf,
"@}",2) == 0) {
2358 else if (strncmp(buf,
"@[",2) == 0 || strncmp(buf,
"@]",2) == 0) {
2361 else if (text[i] ==
']' ) {
2367 else if (text[i] ==
'[' ) {
2373 else if (text[i] ==
'{' ) {
2379 else if (text[i] ==
'}' ) {
2380 if ( nOfCurlyBracket) {
2395 if (nOfKW2 != nOfSquareCurly) {
2397 fError =
"Invalid number of \"]{\"" ;
2399 else if (nOfKW3 != nOfCurlyCurly) {
2401 fError =
"Error in syntax of \"#frac\"" ;
2403 else if (nOfCurlyBracket < 0) {
2405 fError =
"Missing \"{\"" ;
2407 else if (nOfCurlyBracket > 0) {
2409 fError =
"Missing \"}\"" ;
2411 else if (nOfSquareBracket < 0) {
2413 fError =
"Missing \"[\"" ;
2415 else if (nOfSquareBracket > 0) {
2417 fError =
"Missing \"]\"" ;
2447 spec.
fSize = size/hw;
2488 if( newText.
Length() == 0)
return 0;
2498 std::cout<<
"\n*ERROR<TLatex>: "<<
fError<<std::endl;
2499 std::cout<<
"==> "<<
GetTitle()<<std::endl;
2519 if( newText.
Length() == 0)
return;
2530 std::cout<<
"\n*ERROR<TLatex>: "<<
fError<<std::endl;
2531 std::cout<<
"==> "<<
GetTitle()<<std::endl;
2537 Int_t cBoxX[4], cBoxY[4];
2540 ptx =
gPad->UtoPixel(
fX);
2541 pty =
gPad->VtoPixel(
fY);
2547 Int_t x1 = cBoxX[0];
2548 Int_t x2 = cBoxX[0];
2549 Int_t y1 = cBoxY[0];
2550 Int_t y2 = cBoxY[0];
2551 for (
Int_t i=1; i<4; i++) {
2552 if (cBoxX[i] < x1) x1 = cBoxX[i];
2553 if (cBoxX[i] > x2) x2 = cBoxX[i];
2554 if (cBoxY[i] < y1) y1 = cBoxY[i];
2555 if (cBoxY[i] > y2) y2 = cBoxY[i];
2575 if( newText.
Length() == 0)
return 0;
2585 std::cout<<
"\n*ERROR<TLatex>: "<<
fError<<std::endl;
2586 std::cout<<
"==> "<<
GetTitle()<<std::endl;
2648 out<<
" tex = new TLatex("<<
fX<<
","<<
fY<<
","<<quote<<s.
Data()<<quote<<
");"<<std::endl;
2654 out<<
" tex->Draw();"<<std::endl;
virtual void SetLineWidth(Width_t lwidth)
Int_t fLimitFactorSize
Relative position of subscripts and superscripts.
virtual void PaintMathText(Double_t x, Double_t y, Double_t angle, Double_t size, const char *text)
Paint text (used by Paint()).
virtual void GetTextAscentDescent(UInt_t &a, UInt_t &d, const char *text) const
Return text ascent and descent for string text.
static Vc_ALWAYS_INLINE int_v min(const int_v &x, const int_v &y)
Double_t fOriginSize
array of values for the different zones
virtual Color_t GetTextColor() const
virtual Short_t GetTextAlign() const
TString & ReplaceAll(const TString &s1, const TString &s2)
Bool_t TestBit(UInt_t f) const
void Copy(TObject &text) const
Copy this text to text.
virtual Float_t GetTextAngle() const
virtual void GetControlBox(Int_t x, Int_t y, Double_t theta, Int_t cBoxX[4], Int_t cBoxY[4])
Return the text control box.
Short_t Min(Short_t a, Short_t b)
void GetBoundingBox(UInt_t &w, UInt_t &h, Bool_t angle=kFALSE)
Get the text width and height.
virtual void Modify()
Change current line attributes if necessary.
TLatex & operator=(const TLatex &)
Currently inside italic operator.
TString & Insert(Ssiz_t pos, const char *s)
virtual Width_t GetLineWidth() const
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
Int_t PaintLatex1(Double_t x, Double_t y, Double_t angle, Double_t size, const char *text)
Drawing function.
virtual void AppendPad(Option_t *option="")
Append graphics object to current pad.
virtual void Modify()
Change current text attributes if necessary.
TLatex * DrawLatexNDC(Double_t x, Double_t y, const char *text)
Draw this TLatex with new coordinates in NDC.
virtual void SetTextFont(Font_t tfont=62)
static const double x2[5]
void DrawLine(Double_t x1, Double_t y1, Double_t x2, Double_t y2, TextSpec_t spec)
Draw a line in a Latex formula.
Double_t GetYsize()
Return size of the formula along Y in pad coordinates.
void DrawCircle(Double_t x1, Double_t y1, Double_t r, TextSpec_t spec)
Draw an arc of ellipse in a Latex formula (right or left parenthesis)
void Copy(TAttLine &attline) const
Copy this line attributes to a new TAttLine.
virtual void SaveLineAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1)
Save line attributes as C++ statement(s) on output stream out.
virtual Float_t GetTextSize() const
TLatexFormSize Anal1(TextSpec_t spec, const Char_t *t, Int_t length)
Analyse function.
To draw Mathematical Formula.
virtual void Paint(Option_t *option="")
Paint.
static const double x4[22]
TLatex * DrawLatex(Double_t x, Double_t y, const char *text)
Make a copy of this object with the new parameters And copy object attributes.
if on multiple lines(like in C++). **The " * configuration fragment. * * The "import myobject continue
Parses the configuration file.
Base class for several text objects.
TLatex()
Default constructor.
virtual void SetNDC(Bool_t isNDC=kTRUE)
Set NDC mode on if isNDC = kTRUE, off otherwise.
Int_t CheckLatexSyntax(TString &text)
Check if the Latex syntax is correct.
virtual void PaintLatex(Double_t x, Double_t y, Double_t angle, Double_t size, const char *text)
Main drawing function.
virtual void Text(Double_t x, Double_t y, const char *string)=0
void DrawParenthesis(Double_t x1, Double_t y1, Double_t r1, Double_t r2, Double_t phimin, Double_t phimax, TextSpec_t spec)
Draw an arc of ellipse in a Latex formula (right or left parenthesis)
virtual void SetTextAlign(Short_t align=11)
void Copy(TAttText &atttext) const
Copy this text attributes to a new TAttText.
virtual void SetLineColor(Color_t lcolor)
Double_t GetHeight() const
Return height of current pad in pixels.
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save primitive as a C++ statement(s) on output stream out.
TNamed & operator=(const TNamed &rhs)
TNamed assignment operator.
Double_t length(const TVector2 &v)
Double_t GetXsize()
Return size of the formula along X in pad coordinates.
TLatexFormSize Readfs()
Read fs in fTabSize.
virtual void SaveTextAttributes(std::ostream &out, const char *name, Int_t alidef=12, Float_t angdef=0, Int_t coldef=1, Int_t fondef=61, Float_t sizdef=1)
Save text attributes as C++ statement(s) on output stream out.
virtual Font_t GetTextFont() const
unsigned int r1[N_CITIES]
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
virtual void SetTextAngle(Float_t tangle=0)
TLatexFormSize Analyse(Double_t x, Double_t y, TextSpec_t spec, const Char_t *t, Int_t length)
Analyse and paint the TLatex formula.
void GetBoundingBox(UInt_t &w, UInt_t &h, Bool_t angle=kFALSE)
Return text size in pixels.
TLatexFormSize FirstParse(Double_t angle, Double_t size, const Char_t *text)
First parsing of the analyse sequence.
void Savefs(TLatexFormSize *fs)
Save fs values in array fTabSize.
FormSize_t * fTabSize
is true during the second pass (Painting)
virtual Color_t GetLineColor() const
virtual ~TLatex()
Destructor.
static const double x1[5]
Int_t fPos
Maximum allocation for array fTabSize;.
Bool_t Contains(const char *pat, ECaseCompare cmp=kExact) const
To draw TeX Mathematical Formula.
void Copy(TObject &text) const
Copy this TLatex object to another TLatex.
static Vc_ALWAYS_INLINE int_v max(const int_v &x, const int_v &y)
Double_t fFactorPos
Relative size of subscripts and superscripts.
virtual void GetTextExtent(UInt_t &w, UInt_t &h, const char *text) const
Return text extent for string text.
Binding & operator=(OUT(*fun)(void))
Mother of all ROOT objects.
TLatex helper struct holding the attributes of a piece of text.
Short_t Max(Short_t a, Short_t b)
Bool_t fItalic
Current position in array fTabSize;.
R__EXTERN TVirtualPS * gVirtualPS
virtual void SetLimitIndiceSize(Int_t limitFactorSize)
Set limit for text resizing of subscripts and superscripts.
virtual void SetTextColor(Color_t tcolor=1)
TVirtualPS is an abstract interface to Postscript, PDF, SVG.
virtual void SetTextSize(Float_t tsize=1)
virtual void PaintText(Double_t x, Double_t y, const char *text)
Draw this text with new coordinates.
Double_t GetYsize(void)
Get Y size.
Double_t GetXsize(void)
Get X size.
unsigned int r2[N_CITIES]
virtual const char * GetTitle() const
Returns title of object.
virtual void SetIndiceSize(Double_t factorSize)
Set relative size of subscripts and superscripts.
static const double x3[11]
const char * Data() const