Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want my eventual PDF to have all fonts embedded. Using special psdots in pstricks is causing this to fail. Here is a MWE of something which results in non-embedded fonts:






Here is output from pdffonts:

[mishchea@linty mwe]$ pdffonts mwe.pdf 
name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
SDXKYB+CMR10                         Type 1            Builtin          yes yes no       6  0
Times-Roman                          Type 1            Standard         no  no  no      13  0
[none]                               Type 3            Custom           yes no  no      14  0
share|improve this question
Everything is fine with the document! Times-Roman is a default PostScript font and available on all PS-printer or used by one of the GhostScript fonts. The Type 3 font is an internal softfont ehich is created by PSTricks itself on the fly. –  Herbert Sep 27 '12 at 5:49
Nevertheless, the entity to which I'm submitting this document insists that all fonts are embedded, so I need to embed this one... –  Andrey Sep 27 '12 at 14:59
sure that is no problem. I also prefer embedded fonts and in my local config.ps the PostScript fonts are always embedded by default –  Herbert Sep 27 '12 at 15:04
add comment

2 Answers

up vote 3 down vote accepted

if you want to embed standard PostScript fonts then use

\usepackage[dvips={-h tir_____.pfb}]{auto-pst-pdf}

that is the setting for Times-Roman. The font file (in this case tir_____.pfb) is free available in the net. If you want to embed all standard PostScript fonts then use an own config.ps file which enables the embedding of these fonts by default, eg:

 % Partially download Type 1 fonts by default.  Only reason not to do
% this is if you encounter bugs.  (Please report them to
% @email{tex-k@@mail.tug.org} if you do.)

% load extra header files, in this case fonts used by pstricks header
% and perhaps in other places, bit of a waste but better save than sorry
h hvb_____.pfb
h hv______.pfb
h tir_____.pfb
h tii_____.pfb
h tib_____.pfb
h pzdr.pfb

running kpsewhich config.ps in a terminal tells you where your current file config.ps is located, eg:

voss@shania:~> kpsewhich config.ps

And here is the output of your example running with the above -h option:

voss@shania:~> pdffonts Test/Namenlos-4.pdf
name                    type              encoding         emb sub uni object ID
----------------------- ----------------- ---------------- --- --- --- ---------
SDXKYB+CMR10            Type 1            Builtin          yes yes no       6  0
GNSOXG+Times-Roman      Type 1C           WinAnsi          yes yes no      13  0
[none]                  Type 3            Custom           yes no  no      14  0
share|improve this answer
How many times do we need to press _ for the font filename in \usepackage[dvips={-h tir_____.pfb}]{auto-pst-pdf} ? Because it is not so obvious for a glance sight. –  I am who I say I am Sep 27 '12 at 6:51
from history: file names were 8.3 characters. 8 for the name and 3 for the extension. –  Herbert Sep 27 '12 at 7:02
Thanks! I only have one question: does enabling this cause the whole font character set to be loaded into the PDF, or just those characters I actually use? In other words, if I set my config.ps as described here, will it cause EVERY PDF I generate to have EVERY PostScript font embedded unnecessarily? –  Andrey Sep 27 '12 at 17:52
As seen in my output of pdffonts it is a subset –  Herbert Sep 27 '12 at 18:56
add comment

I think it is better to use standalone class and compile the source with latex-dvips-ps2pdf compilation sequence to get a tight, single PDF output as follows,

enter image description here

% this file name is goo.tex




Invoking pdffonts goo.pdf produces an output as follows,

enter image description here

Tips and tricks:

  • First, create a single LaTeX input file with standalone class for every PSTricks pspicture you have in your main LaTeX input file.

  • Second, compile each of those standalone-based LaTeX input files with latex-dvips-ps2pdf sequence to produce a PDF output.

  • Third, from within your main LaTeX input file, import those PDF output with \includegraphics and compile the main LaTeX input file with pdflatex.

  • Done!

Does the main LaTeX input file embed the fonts?

% this file name is main.tex

compile it with pdflatex main to produce a PDF file named main.pdf. Then check the fonts as follow,

enter image description here

share|improve this answer
I am not familiar with the standalone class, but this problem is actually buried in the middle of what typesets to a 160 page document which is a finished product except that this single font will not embed correctly. It is thus undesirable to change the document class... –  Andrey Sep 27 '12 at 5:26
Anyway I just tried the latex-dvips-ps2pdf route, also latex-dvipdf, on my actual document, and both gave a PDF with the same unembedded font. –  Andrey Sep 27 '12 at 5:30
I may end up having to do this, but I have around 90 or so figures... in the future I will try to avoid using my method, which apparently causes problems, but if there is a more workable solution for my actual situation I would prefer it. –  Andrey Sep 27 '12 at 5:46
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.