lilypond-devel
[Top][All Lists]
Advanced

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

Re: Cross-staff stem engraver (was: New frog in an empty pond?)


From: Pavel Roskin
Subject: Re: Cross-staff stem engraver (was: New frog in an empty pond?)
Date: Fri, 2 Mar 2012 23:26:17 -0500

Hello!

On Tue, 28 Feb 2012 15:14:29 -0800
Joe Neeman <address@hidden> wrote:

> Don't use ly:axis-group-interface::add-element, because stems don't
> implement the axis-group-interface. (Removing this will also remove
> the axes warning.) Instead, use ly:grob-set-parent!. You'll probably
> want to set both the X parent and the Y parent. Then the X and Y
> offsets of new-stem will be measured relative to stem (instead of
> relative to the whole system, which is the default).

OK, this is what I have now.  I think it's a pretty good solution.

The code is capable of creating multiple cross-staff stems per moment.
It's possible to connect more than two stems as long as they lie on the
same line.  There is a workaround for a problem with Lilypond 2.14 that
has a flag as part of the stem.

I spent way too much time on the issue, but it helped me learn
Scheme and Lilypond.

I'll be on vacation next two weeks, so I'm not sure I'll be able to
work on Lilypond.  So I want to post my results.

I tried posting this on LSR, but it won't accept it.  I get a popup
message saying "empty output from Lilypond" or something like that.  I
guess it's because LSR still runs Lilypond 2.12.x.  Unfortunately, I
have no time for backports.

I'm attaching the Scheme code with a convoluted example (3 staves with
3 voices on each).

The Scheme part is already used here:
https://gitorious.org/lilypond-music/lilypond-music/blobs/master/Schubert/Die_Forelle.ly

-- 
Regards,
Pavel Roskin

Attachment: stemspan.ly
Description: Text Data


reply via email to

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