\ell symbol in PDF

Hi Dear ROOTers and speficially @couet,

I have been trying to get the \ell symbol in PDF unsuccessfully. I’ve read through \ell symbol in TH1 axis - #10 by heico which summarises the problem. Since the previous post is from 2017, I was wondering whether the issue has been resolved. Interestingly, I can get other symbols such as #mu, #phi, #alpha etc. rendered in PDF. A short working code snippet example is:

latex2 = TLatex()
latex2.DrawLatex(0.20,0.73, "Z' #rightarrow #mu#mu +(j_{b}/j_{b}j_{b})")

which alas stops working once I change #mu#ell.

Any suggestions? I emphasise that I care about PDF rendering (I’ve managed to get the #ell symbol in PNG).

Cheers,

Roy

_ROOT Version: 6.22/06
Platform: Linux
Compiler: Python 3.7.6

\ell needs TMathText and TMathText does not work for PDF. You should use PostScript instead.

Hi @couet,

Thanks for your quick reply.
Could you kindly provide a code snippet example similar to mine which would employ PostScript instead to Latex as you suggest?

Cheers,

Roy

You only need to save your canvas as a “*.ps” (or “*.eps”) file (instead of a “*.pdf” file).

Hi,

Many thanks.
It would be nice if some update were to be implemented which would allow this in PDF too (make TMathText work in PDF or at least add #ell specifically to TLatex). IDK whether this is possible…

Cheers,

Roy

TLatex latex2;
latex2.DrawLatex(0.20, 0.73, "Z\\' \\rightarrow \\ell \\ell + ( j_{b} / j_{b} j_{b} )");

Indeed, this works for eps, png… But not for pdf…

As said in the documentation after the tables of characters you can see here: ROOT: TMathText Class Reference

I see… Thanks.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.