lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

lilypond-book and searchable pdf:s


From: Erik Ronström
Subject: lilypond-book and searchable pdf:s
Date: Sat, 12 Jan 2008 01:57:21 +0000 (GMT)

Hi!

This is not a question, rather I would like to just present some things
I've come across the last days. Maybe this is old knowledge to you, and
in that case, please ignore this mail. Still, I was not able to find
these my conclusions in the archives, so hopefully it may be of some
use for someone!

I'm typesetting a book with lilypond and LaTeX, using lilypond-book to
put it all together. However the text in the resulting pdf file is not
searchable or copyable by Acrobat or Preview.app. After many hours of
error checking, I found out what is causing my problems and some
workarounds.

The problem seems to be that when the fonts are encoded with T1
encoding in LaTeX, the resulting pdf does not have a correct character
mapping, and thus can not extract any text.

As several people earlier have pointed out, there are some workarounds:

1) Use the CMAP package for LaTeX
2) Use a standard postscript font, like times
3) Use the default OT1 font encoding instead of T1

The CMAP package works perfectly and magically takes care of
everything. However, it only works with pdflatex and not with dvips,
which is a problem when I'm using lilypond-book (since I can't make
pdflatex work with my generated tex files from lilypond-book, I have to
use dvips)

Using times instead of the CM fonts work - but I don't want times!

Using OT1 font encoding has two problems: a minor problem is that the
pdf renders a bit ugly on-screen in Acrobat, compared to when using T1
fonts. Worse is that the OT1 fonts only contain a basic extended ASCII
set of glyphs, which means that many non-english characters are
missing!

Conclusion:
* I can have a searchable pdf, but in that case I have to sacrifice
either the font or the encoding (meaning all non-english chars), OR
* I can have a complete, perfectly looking pdf, which is not
searchable, OR
* I can get it all if I use the cmap package for LaTeX. But then I have
to use pdflatex instead of dvips, which doesn't work with
lilypond-book!

As far as I can tell, there is no solution to this problem.

HOWEVER: Making cmap work with dvips is on the TODO for cmap. I emailed
the creator of the cmap package, and he says that he "think[s] it is
possible to make it work with dvips, but it needs some hacking and
time". He continues "unfortunately i currently don't have time for
this. if you can help, or know someone who is interested in this,
please let me know."

I don't have enough skills for such a task, but maybe someone on this
list has? And I want to ask the LilyPond team: can this be a candidate
for sponsoring, even though it is not really a part of lilypond itself?

Best regards
Erik Ronström



      __________________________________________________________
Sent from Yahoo! Mail - a smarter inbox http://uk.mail.yahoo.com





reply via email to

[Prev in Thread] Current Thread [Next in Thread]