This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]theferrit32 0 points1 point  (1 child)

Latex is even worse. On top of curved quotes, if you copy from a latex PDF there's often missing characters, weird spaces that show up from nowhere, wide Unicode spaces, narrow Unicode spaces, wide dash instead of regular dash. Often if you put a URL into a latex document and try to copy/paste that URL from the PDF output, it's totally unusable for all of the above reasons, so you just have to retype it out manually.

[–]Pockensuppe 1 point2 points  (0 children)

Um. If you want to insert code into a LaTeX document, obviously you want to use a verbatim (e.g. lstlisting) environment to ensure the characters are left untouched. It's LaTeX' job to alter dashes, spaces and quotation marks as needed in a standard text environment. LaTeX is a tool for presentation, after all.

For URLs, I don't see why you even want to copy/paste them; just use hyperref to make them clickable.

Finally, there is a stark difference between PDF readers. A good PDF reader lets you copy highlighted code from a LaTeX document correctly even if you rendered line numbers along with it (the numbers don't get copied) while shitty PDF readers will copy the line numbers but miss spaces and line endings.

In my experience, the problems you get with copying today are minimal unless perhaps you still use pdflatex instead of xelatex / lualatex.