On Mar 11, 2012, at 8:53 AM, James Harkins wrote:

> At Sun, 11 Mar 2012 08:12:35 +0100,
> m...@apollinemike.com wrote:
>> The best way to achieve that with current LilyPond is Scheme engravers.
>> 
>> There have been a few examples of Scheme engravers posted on this list (if 
>> you search Scheme engraver you'll find one - there are also examples in the 
>> input/regression folder of the LilyPond source).  You'd want to create one 
>> that begins and ends a spanner when it hears a given event (you can invent a 
>> BoxNoteEvent, for example) and acknowledges note columns in the interim, 
>> putting them in a grob-array called "note-columns" or what-have-you.  Then, 
>> make a print method that extracts these note columns (or whatever grobs 
>> you're interested in) finds the min/max height and width, and draws a box at 
>> those dimensions.
>> 
>> If you want to get fancy, you can add extra spacing width to the left of the 
>> first note column and the right of the last note column to make sure there 
>> are no collisions with the box and surrounding material.
> 
> I see... would it be too much to ask you to send your engraver to me (off 
> list if you prefer)? That's of course assuming you developed one for your own 
> music. Normally I don't mind doing some research and experimentation on my 
> own, but in this case --
> 

Unfortunately, the way I created mine was way hackish and not at all 
extensible, intelligent, or suitable to your needs (I hijacked a beam grob).
The best thing to do is go ahead w/ the score as if it were to have boxes and 
then put something like :

c d
%\startBoxedNotes
e f g
%\endBoxedNotes

wherever you need it.  There are enough people on this list who know Scheme 
that someone is likely to pop up w/ a more fleshed-out solution in the next 6 
weeks, and if not, in 6 weeks (if not less), I'll have some time to give it a 
go.

Cheers,
MS


_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to