>From your post is not wuite clear if you managed to include your .ly file >automatically in LyX by simply selecting it in "External Material" If yes, you would be asking to get rid of the pag-size problem.
Well, I've (almost) done it! (Thanks to a old post I found googling) You just need your .ly files correctly called by LyX. You just have to add this code to your .ly file: \header{ copyright = "" tagline = ""} as well as \paper{ragged-right=##t} (or ragged-last=##t if the excerpt is longer than 1 line) The resulting pdf or png or ps (don't know which is the auto temporary file, I simply don't care) is clipped in its heigth, but not in its width (I'm working on this). You can use it in in-line text with proper scaling but this may require some manual clipping (in the Lyx external file option tab) to cut some white space in the right side. Also you may require to quit the indent space of the 1st line in the .ly file, by setting it to zero. If you use the fragment in a paragraph or in some box, you also may need to manage some clipping, expecially if the fragment is longer. If you need a big fragment which spread along more than one page, I still can't help you effectively. I think it would be too difficoult to have the clip-invoking option of Lilypond work with LyX, but perhaps you can manage the problem of splitting your music by producing two or more supplemental .ly file which just "quote" only the x line of the master .ly file, and input them one after the other with lyx, expecting LyX to change page when there's no more space. I read about quoting somewhere in the lily docs, but can't remember where. You may also set some Lilypond layout properties (including the mentioned \header or \paper properties) by default so each example match scaling and width/heigth of your LaTeX document class. I use Komascript book and I will try write this code for me. Let me know if this work and if there're some issue cause I want to use Lilypond this way too. Piero _________________________________________________________________ Party… con Eventi! Condividi foto e commenti sulla tua festa! http://www.microsoft.com/windows/windowslive/events.aspx