Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

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 it now contains a hyphen followed by a space character.

\parbox{2cm}{Break lexicon here.}
share|improve this question
Adobe Reader 10.1.2 on Mac has no problem finding "lexicon". But surprisingly, Preview 5.0.3 can't find it. BTW, great MWE. I just wish more people would provide this. –  Peter Grill Feb 1 '12 at 5:45
You're right, I wrote about Acrobat (which I have installed but didn't try) but tested Preview. So I guess it is really a question of the respective program's search algorithm and not the file format. –  Till A. Heilmann Feb 1 '12 at 5:53
@Dror: Since Skim uses OSX's PDF routines – as does Preview –, that's not surprising. –  Simifilm Feb 1 '12 at 9:29
@AymanElmasry But there could be a nice LuaTeX solution to overcome that problem. –  topskip Feb 1 '12 at 9:37
I am thinking: Shouldn't this (i.e. making hyphenated words searchable, by whatever means) be standard behavior for pdfTeX or LuaTeX when generating a PDF? Searching PDFs for expressions is such a common thing, really. –  Till A. Heilmann Feb 1 '12 at 12:10

1 Answer 1

up vote 5 down vote accepted

Searching the PDF output here is really a function of the viewer. As such, each one takes a different approach to what it will work with. You see that not only with hyphenation but also with other awkward items.

share|improve this answer
Indeed : I tried the provided MWE under Linux with Evince, ePDFreader and Okular. Verdict : no, no, yes. –  rcabane Nov 24 '12 at 7:43

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.