[pdftex] Blank lines are ignored when copying-and-pasting from PDF

martijn.list martijn.list at gmail.com
Sat Jan 2 20:18:33 CET 2010

 > This might be difficult because PDF has no concept of lines.  It only
 > contains information where text or graphics shall appear on the page.
 > I tested your example with ps2ascii (Ghostscript) and pdftotext (xpdf)
 > and both didn't even recognize ordinary line breaks.  I assume that
 > copy-and-paste will never be reliable if the exact formatting matters.
 > But I tried something different which might be an option, though
 > probably not supported by all PDF browsers:
 > Put the key into an external file "PGP.txt" and run the file below
 > through pdflatex:

Hi Reinhard,

Interesting workaround (attaching the key). The only problem I have with 
PDF attachments is that I want the PDF to work with all PDF readers. The 
PDF is an installation manual for my open source project and I want it 
to work even when the PDF reader does not support attachments.

I tried to insert spaces etc. but it seems that all spaces are removed. 
I have search the web quite intensively for a solution but haven't found 
one. You would think that this is problematic for others as well, for 
example when including source code snippets. I have tried the listings 
package (which is used for including source code) but it suffered from 
the same problem.

Kind regards,

Martijn Brinkers

Djigzo open source email encryption

More information about the pdftex mailing list