The issue
I compile a latex document which contains accents ("é" for instance), then I copy the text from the pdf generated by pdflatex. Then, I paste this text to my latex file.
The resulting file cannot be completed, for some encoding reason.
Is there a way to solve this problem?
PS:
My system is OSX. My TeX distribution is TeXLive. My PDF previewer is Preview (the default Apple previewer application).
PPS:
This problem seems to be related more to Apple's Preview application than anything else.
Minimal non-working example
\documentclass{article}
\usepackage{cmap}
\usepackage[french]{babel}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\begin{document}
Copy this text "éàoùôêèç" and then paste it here : éàoùôêèç
Then compile again.
\end{document}
The error
./Sans-titre.tex:10: Package inputenc Error: Unicode char \u8:Ì not set up for use with LaTeX.
See the inputenc package documentation for explanation. Type H for immediate help. ...
l.10 ... oùÎêÚç" and then paste it here : eÌ aÌouÌoÌeÌeÌç

\input glyphtounicode \pdfgentounicode=1when I am using theIL2font encoding, or, I am usingxelatexandlualatexengines without theinputencpackage (I am usingfontspecinstead). – Malipivo May 06 '14 at 12:26