# TLatex/TMathText with math input and TCanvas PDF export

I have a plotting skript, including a TLatex text input for the center of mass energy and lumi, i.e. including a \sqrt and a \int command.

tl = TLatex() tl.SetTextSize(0.1) tl.SetNDC() tl.DrawLatex(0.2, 0.6, "\sqrt{s} = 8 TeV") tl.DrawLatex(0.2, 0.4, "\int L dt = 20.3 \; fb^{-1}")

The output in *.png and *.eps look fine, but the *.pdf output just shows a single line for the \sqrt output and nothing for the \int output (see attached screenshot)

I found some related posts but none really solving the issue!?

I am using
/cvmfs/atlas.cern.ch/repo/ATLASLocalRootBase/x86_64/root/5.34.25-x86_64-slc6-gcc48-opt/bin/root

But I confirmed the same behaviour with
/cvmfs/atlas.cern.ch/repo/ATLASLocalRootBase/x86_64/root/6.02.12-x86_64-slc6-gcc48-opt/bin/root
/cvmfs/atlas.cern.ch/repo/ATLASLocalRootBase/x86_64/root/6.04.02-x86_64-slc6-gcc48-opt/bin/root

minimal working example MWE.py attached

MWE.py (527 Bytes)

I see the same behaviour when using TMathText

tm = TMathText() tm.SetTextSize(0.1) tm.SetNDC() tm.DrawMathText(0.2, 0.4, "\sqrt{s} = 8 TeV") tm.DrawMathText(0.2, 0.2, "\int L dt = 20.3 \; fb^{-1}")

Minimal working example MWE2.py attached
MWE2.py (698 Bytes)

Thanks for the reference to JIRA.

This isse indeed seems to be quite old (August 2013), so I guess I can not expect any updates in near future?

Did you see the second link here? (deals with exactly that question)

[quote=“Wile E. Coyote”]
https://root-forum.cern.ch/t/tmathtext-in-pdf-svg-export/19505/1[/quote]

Seems to me, you’d better not expect this to be fixed in the near future