On 31/08/10 20:03, Etienne Snyman wrote:
Hi Torquil!

Thanks for the reply. Please find my replies to your comments in-line:

On Tue, 2010-08-31 at 19:08 +0200, Torquil Macdonald Sørensen wrote:
Do you want to write Lilypond code directly in LyX, and have LyX automatically
run the necessary 'lilypond-book' script in order to generate LaTeX code that
can be compiled to PDF?

That would actually be a great addition. How complicated do you think
that would be?

I have no idea :-) You'de have to hope for an answer from one of the LyX 
experts.

Or do you just want to include/link an external Lilypond file?
I successfully did the latter as follows:

Go to the menu item: Insert ->  File ->  External Material

Then select Lilypond on the Template drop-down menu on the File tab. Select the
*.ly file in the File: field. The other tabs allow you to adjust e.g. size and
rotation.

Within LyX I then see a grey box with the text "Lilypond typeset music". The
music is of course present in PDF files produced with LyX.

These steps are fine. However, when I wish to preview the PDF output,
get the following error message:

"No information for converting lilypond format files to pdf.
Define a converter in the preferences."

If I go to the preferences dialogue box, I am too confused and too
computer-literate to figure out what's wrong.

First of all, according to the Lilypond dropdown menu choice in the External Material dialog window, Lilypond 2.9or newer is needed for PDF outout, and Lilypond 2.6 or newer for PS. You can check you Lilypond version by executing "lilypond -v".

Secondly, looking in my LyX preferences, I do find the following related to Lilypond:


Under "File Handling -> File formats", I have the following entry in the "Formats" drop-down menu:

"Lilypond music"

The settings are:

"Document format" not ticked
"Vector graphics format" is ticked
Short name; lilypond
Extension: ly
Shortcut:
Editor: sensible-editor
Viewer:
Copier:

The "sensible-editor" is something related to my operating system (Debian). I don't think it matters for the funcionality you are after.

Under "File Handling -> Converters -> Converter Definitions", I have the following three instances, with the following settings:

* "Lilypond -> EPS":

From format: Lilypond music
To format: EPS
Converter: lilypond -dbackend=eps --ps $$i
Extra flag:

* "Lilypond -> PDF (ps2pdf)":

From format: Lilypond music
To format: PDF (ps2pdf)
Converter: lilypond -dbackend=eps --pdf $$i
Extra flag:

* "Lilypond -> PNG":

From format: Lilypond music
To format: PNG
Converter: lilypond -dbackend=eps --png $$i
Extra flag:

You could check if you have the same settings as me. These are default LyX settings here on Debian. I haven't changed them.

Best regards
Torquil

Reply via email to