One frequent aspect of
pdflatex output that could be improved is to what extent one can select text output from the generated pdf-file and copy-and-paste it. This is essentially an issue of having the right output encoding. There are at least two important aspects to this:
- In the ideal case, Unicode would be the output encoding.
- Ligature glyphs (such as ﬁ) are ideally de-ligated in the output (here: "fi").
It seems that output encodings are specified through the
fontenc package. What is the range of possible output encodings, and most importantly: Is there a way to specify a Unicode output encoding and one that deals with ligatures in the intended way?
(Note: It is important to distinguish output from input encodings. How to use different input encodings in LaTeX has been documented widely. My understanding is that this is best handled by the
inputenx package, as it supersedes the
Quick guide to the solutions: The information in the answers and answer threads is a bit distributed, so here the short summary: one approach is to use
\input glyphtounicode together with
\pdfgentounicode=1; the other approach is to use