2

I have a plot in pdf format which I include in my LaTeX document with \includegraphics. When I use pdflatex to compile I get

pdfTeX warning: /usr/bin/pdflatex (file /usr/share/texlive/texmf-dist/fonts/type1/public/stix/STIXGeneral-Italic.pfb): glyph `afii61289' undefined

and indeed one particular symbol from the plot is gone in the pdf. (The plot was created with TMathText in ROOT, exported as eps and converted to pdf. The missing symbol is "\ell".)

Looking through the answers here, I found the \pdfmapline command. Not knowing exactly what is does I tried to include

\pdfmapline{KEAHSX+STIXGeneral-Italic}

at the beginning of my .tex file and indeed, compiling took a while and the missing symbol is now there. But. The font of the text body is now replaced by a pixel font, which obviously I don't want. (The fonts in included pdf plots are fine.)

So is there a better way to solve my original problem?

MWE

\documentclass{article}
\usepackage{graphicx}
\begin{document}
\includegraphics[width=\textwidth]{missing_ell.pdf}
\end{document}

missing_ell.pdf: download here

The pdf has the \ell the output when running pdflatex doesn't.

Create the plot

To recreate the plot (note: you can just download the file from the link above), do this in ROOT6:

a = new TH1F("h","h",1,-0.5,0.5)
a->GetXaxis()->SetBinLabel(1, "\\text{VR }W+\\,\\text{jets }(m_\\text{T2}(\\ell,\\tau))")
a->Draw()

Draw canvas as eps, convert to pdf with epstopdf.

4
  • Let me know in case I should add more information, e.g. the output from pdffonts etc. For the final pdf it's pretty long so I decided against including it for now, as I don't think it has additional information. KEAHSX+STIXGeneral-Italic is embedded in both the plot and the final pdf. Commented Aug 2, 2016 at 9:30
  • You should make a minimal example that we can use for tests. Naturally the pdf of the plot you are including is needed too. Commented Aug 2, 2016 at 9:38
  • I was afraid you'd ask for that as the plot is not public yet... I'll try to come up with a dummy plot. Commented Aug 2, 2016 at 9:53
  • I added an MWE. Commented Aug 2, 2016 at 12:42

2 Answers 2

5

Try this (it will make your pdf larger).

\documentclass{article}
\pdfinclusioncopyfonts=1
\usepackage{graphicx}
\begin{document}
\includegraphics[width=\textwidth]{missing_ell.pdf}
\end{document}
4
  • Thanks, fixes the problem, and the size increase is O(1 %). I can live with that :) Commented Aug 2, 2016 at 12:44
  • Unfortunately, this does not seem to work in beamer? Commented Mar 21, 2017 at 9:41
  • My comment above below your question is still valid. Commented Mar 21, 2017 at 9:46
  • Putting \pdfinclusioncopyfonts=1 as first line (before the line with \documentclass) works in beamer. Commented Nov 30, 2020 at 16:03
0

Here is an EPS file with script ell created with ROOT6.22/02 https://www.dropbox.com/s/03n8y8xjtxkalvz/ell1.eps?dl=0.

I find the simplest approach is to use a bulk editor to replace STIX with STIXX in the eps files before conversion. This helps to remove the conflict between the version of STIXGeneral-Italic in ROOT (Version 0.9) and that included in TeXLive (version 1.1-beta1 for TeXLive 2017).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .