{copy-paste} is about copying text and other elements from one place (often a PDF file) and allowing it to be pasted. Searching for text (in a PDF file) is a process closely related to copying because both use the OCR (optical character recognition) layer in the PDF file.

learn more… | top users | synonyms

14
votes
1answer
1k views

Copy from PDF without line breaks at end of each line

When I produce the PDF, open it and copy the paragraph into notepad, there is a forced line break at the end of every line in the PDF. Is there a way to get over this, so that I can copy the paragraph ...
12
votes
2answers
440 views

Encoding to be able to search pdf

I am writing a document in Czech. I want To be able to fully search the pdf (at the moment I can search only for words with non-Czech characters, but I want to be able to search with Czech ...
16
votes
1answer
525 views

Are there any (La)TeX editors that accept pasting rich text?

If I copy text to the clipboard from a PDF file, web page, email, or Word document and then paste it to Word or Thunderbird, it is recognized as rich text and converted to Word's or Thunderbird's ...
13
votes
1answer
608 views

Can we make ligatures copy-and-pastable? [duplicate]

Is there a straightforward way to make ligatures more copy-and-pastable? I know that by using \usepackage[t1]{fontenc} that many glyphs like accented and umlauted characters become ...
8
votes
1answer
755 views

Copying LaTeX from a PDF

Is there a way to copy from a PDF to a LaTeX document? Whenever I do it, it copies in with weird symbols in the place of LaTeX commands for example: $$f:\mathbb{R}\rightarrow \mathbb{R}$$ copies in ...
8
votes
1answer
390 views

How can I make source code included with minted copyable?

Is it possible to make source code with minted copyable? Here is a minimal example how I include source code (completely, with minimal java code, on GitHub): \documentclass{beamer} ...
6
votes
0answers
189 views

PDF that can be scanned faster by a PDF reader [closed]

Searching words with Ctrl+F in common PDF readers takes sometimes very long. The time does not correlate with the number of pages, or the number of embedded pictures. What causes slow fulltext ...
7
votes
1answer
282 views

Copy Czech characters from PDF with charter font

I wanna be able to copy czech characters from PDF, but for some reason it doesn´t work. here is my code: \usepackage{cmap} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{charter} ...
11
votes
4answers
2k views

Copy-and-paste of mathematical formulas pastes the unformatted, raw TeX

For instance: Copy Paste in a new location Result: x^{2} LyX 2.0.4 (new)/MiKTeX/Windows 7 Ultimate 64 bit
13
votes
2answers
366 views

How to produce character-by-character-pastable visual output that is a function of the (intended-to-paste-as-such) source code input?

Note: The original phrasing of my question was this: How to use accsupp to produce all-upercase in the visual output from input that should paste in its original, ordinary-case form? However I think a ...
13
votes
1answer
365 views

Hyphens at end of line disappear upon pasting, even if they were present in the input

When I paste text from pdflatex output, there are two things about hyphens that I would like to change: Hyphens paste as "hyphen-minus" (U+002D, "-"), but I would prefer the newer Unicode character ...
5
votes
1answer
1k views

How to make slash (/) paste with correct Unicode codepoint depending on context?

Unicode offers different characters for the slash: U+002F (/) for the ordinary slash U+2215 (∕) for the mathematical division operator U+2044 (⁄) to designate vulgar fractions How can I have these ...
4
votes
0answers
56 views

XeLaTeX oldstyle figures search/copy [duplicate]

Possible Duplicate: Small-caps, old-style numbers, and some ligatures produce odd symbols in PDF copy text? How can I make XeLaTeX produce PDFs that can be searched/copied? In particular, ...
5
votes
1answer
320 views

pasting small circled (\textcircled) letters leads to incorrect (reversed) Unicode codepoint sequence for combining circle

When I try to circle a small letter, compile (using glyphtounicode.tex), and then paste the resulting text, the combining circle (U+20DD) appears before the letter (here: "b") even though it, being a ...
1
vote
1answer
191 views

How do I paste codepoints outside of the basic multilingual plane with accsupp or \pdfglyphtounicode?

As described in the answers to this question, the accsupp package can be used to have symbols paste as arbitrary Unicode codepoints. For example you might want to write something like the following, ...
6
votes
2answers
14k views

How to make apostrophes appear normally when copy-pasting from a MS Word document?

I have a report written in MS Word which I would like to turn into a LaTeX document. I copy-pasted the content of the document in my LaTeX editor (TeXShop, LaTeX, pdfTeX) and everything comes out fine ...
3
votes
1answer
1k views

Weird behaviour of copying - no space between words

\documentclass{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{tgtermes} \begin{document} Polska, Rzeczpospolita Polska -- państwo unitarne w Europie Środkowej, położone ...
5
votes
2answers
331 views

Unable to copy _ from pdf

\documentclass{article} \usepackage[T1,OT4]{fontenc} \begin{document} Text with \_. \end{document} In PDF there is a correct output: Text with _. But when I select and copy it I get: Text with . It ...
12
votes
1answer
547 views

Can PDF search find words with ligatures in XeLaTeX-documents?

Is there some way allow PDF search to find words with ligatures? I use XeLaTeX. \documentclass{book} \begin{document} Prefix. \end{document} In the resulting pdf file, searching for the word ...
14
votes
2answers
902 views

How to fix missing or incorrect mappings from glyphtounicode.tex

glyphtounicode.tex has been described as the best solution for generating copy-and-pasteable symbols. However, I find that various symbols that I need to use do not paste as the appropriate Unicode ...
8
votes
3answers
1k views

Incompatibilities of cmap with fontenc/hyperref?

The following code doesn't compile (with pdflatex) \documentclass{article} \usepackage{cmap} \usepackage[T1]{fontenc} \usepackage[pdfa=true]{hyperref} \begin{document} Hello. \end{document} ...
65
votes
6answers
5k views

What are good ways to make pdflatex output copy-and-pasteable?

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 ...
4
votes
1answer
554 views

How to copy contents of one file to another?

So I have a .txt-file and I need to import the data line per line. That works like it should. I need however to adapt the contents loaded into a command an write it to another .txt file that later ...
15
votes
1answer
987 views

Remove hyphen from word spanning two lines in text copied from a pdf file

If I copy text from a PDF and a word is hyphenated and spans two lines, the copied text contains the "-". For example: Examp- le should be copied as Example not Examp-le The problem is ...
4
votes
2answers
379 views

Cannot copy letters with diacritics from pdflatex PDF

I have problem with copying text from PDF file. I am using these packages in my document: \usepackage[slovak]{babel} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} However when I generate ...
10
votes
2answers
650 views

pdf files show “fi”, but searching for or copying them does not work

When I pdflatex text containing "fi", e.g. "infinite", the resulting pdf-file looks correct, e.g. "infinite" is shown in the text. But when I search the pdf file for "infinite", 0 occurrences are ...
62
votes
3answers
2k views

Is there a LaTeX trick to prevent a PDF viewer from copying the line number?

A PDF output is obtained by compiling the following code. \documentclass{article} \usepackage{xcolor} \usepackage{listings} \lstset { language={[LaTeX]TeX}, numbers=left, ...
5
votes
2answers
569 views

Problems with copy and paste from PDF using lstlisting (Again)

So I had already posted a similar question concerning the minus sign (-), but now I have an issue with the apostrophe (') that the previous solutions do not seem to solve. This seems to be a problem ...
8
votes
3answers
1k views

Problems with copy and paste from PDF using lstlisting

I'm using lstlisting to create course notes from which I am hoping that code can be copy&paste'd I've already implemented the suggestions in Phantom spaces in listings (pdf) to make sure that ...
7
votes
1answer
442 views

Copy-able Matrix/Grid

I have grid-formatted data: 1 2 3 4 5 6 7 7 9 I'd like to display this as above in a LaTeX document compiled with pdfLaTeX. I've thought about using the TikZ Matrix library and the AMSMath Matrix ...
4
votes
1answer
195 views

What exactly does \pagenumbering do?

I am trying to squelch the page numbers using the code from here. This works fine, if one uses ordinary page numbers. If the page numbers are modified with the pagenumbering command, it doesn't work ...
6
votes
1answer
327 views

Create alternative uppercase text automatically with accsupp

This is a follow-up question to Is it possible to provide alternative text to use when copying text from the PDF?. I am essentially trying to redefine textsc/scshape in order to use accsupp ...
26
votes
1answer
759 views

Is it possible to prevent some part of text (headers, footers) from selection?

I'm looking for a solution that will allow me to prevent some parts of the final pdf file (header, footer) from being selected and copied. It is to allow easier quoting of longer parts of texts from ...
51
votes
1answer
3k views

Small-caps, old-style numbers, and some ligatures produce odd symbols in PDF copy text?

This is a problem I've had consistently with XeLaTeX. Here's a small example: \documentclass{article} \usepackage{fontspec} \setmainfont[Ligatures=TeX,Numbers={OldStyle,Proportional}]{Minion Pro} ...
10
votes
5answers
2k views

I just want to have the text in my pdf the same way I have it in my editor

I want to paste from the clipboard a plain text copied from a text editor (line wordpad++, vim, notepad etc), and I want TeX to respect the same line break formatting that the editor has. This works ...
3
votes
1answer
4k views

Copy and paste disabled in LyX 2.0

I try to copy and paste in a LyX document I am editing and it says that the command (paste) is disabled. This happens with anything, be it normal text, figures or formulae. I am working on a 64 bit PC ...
28
votes
1answer
761 views

Make hyphenated words in PDF searchable

Is there a way to make hyphenated words in a PDF generated by LuaTeX searchable? If the MWE below is converted to a PDF, searching for "lexicon" (in Acrobat X for example) will not find the word since ...
7
votes
1answer
2k views

Copy pasting of underscore

When I use \textunderscore to print an underscore "_" character, the copy-paste functionality of Adobe Acrobat Reader does not appear to work properly. For instances, when I copy test_case from ...
11
votes
2answers
1k views

What can cause generated PDF document whose text are not correctly copyable?

I was wondering why some PDF documents compiled from some LaTeX code does not make its text correctly copyable, i.e. what you can get is nonsense text? For example, this pdf document (I don't have the ...
7
votes
2answers
656 views

How do I encode foreign characters so that they are searchable in the resultant PDF file?

This may be a PDF problem rather than a LaTeX problem, but as it involves pdfLaTeX output I'm hoping I won't get my wrist slapped too hard. I'm creating a bibliography, and inevitably some of the ...
5
votes
1answer
199 views

Selectable picture environment in PDF

I'd like to be able of copy & pasting the results of a picture environment in a PDF file to a plain text file. The problem is that once I copy the text the results are unsatisfactory: for ...
2
votes
0answers
454 views

Cannot copy from pdflatex-created PDF [closed]

When I create a PDF using pdflatex, I can neither copy from it nor search across lines. Is there any way to make these things possible? I tried cmap, but it doesn't help at all. Here is an example ...
22
votes
1answer
995 views

How to make text copy in PDF previewers ignore lineno line numbers?

I'm using lineno for a document. I have it configured to put line numbers in the margins of the document. I generate PDF using pdflatex. Here's the problem: when people copy a region of text in a ...
7
votes
1answer
3k views

Problem copying text from pdf - spaces being stripped

I have the following minimal working example: \documentclass{book} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \begin{document} é canção \end{document} I need to use the utf8 argument ...
10
votes
3answers
4k views

How to make listings code indentation remain unchanged when copied from PDF?

So I am using listings package for code examples. But there is a problem. When I copy the code examples from the final PDF document, they are usually not the same - the indentation is gone, there are ...
6
votes
1answer
931 views

PDF with un-copyable text in LuaLaTeX

In Is it possible to produce a PDF with un-copyable text?, it was suggested the following code to disable the coyable text from a pdf viewer. % pdflatex is required \documentclass{article} ...
12
votes
1answer
6k views

Protect text in PDF from being copied [duplicate]

Possible Duplicate: PDF with un-copyable text What is the most effective ways to protect text in a PDF from being copied with Ctrl+C? I know about standard PDF copy protection, and also ...
42
votes
7answers
16k views

Is it possible to produce a PDF with un-copyable text?

Is it possible to produce a PDF with un-copyable text? I mean, when you want to copy text from the PDF, you can't copy it or what you copy is nonsense characters.
35
votes
1answer
2k views

Make ligatures in Linux Libertine copyable (and searchable)

I'm currently working on an essay written in LaTeX form. I'm facing problems with ligatures - in my pdf output (rendered using pdftex) opened in Adobe Reader I get X's and V's when copy-pasting words ...