bug-lilypond
[Top][All Lists]
Advanced

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

Re: FullCadenzaRest?


From: Neil Puttock
Subject: Re: FullCadenzaRest?
Date: Sun, 12 Sep 2010 22:15:59 +0100

On 8 September 2010 18:50, Alexander Kobel <address@hidden> wrote:

> Okay, this spares the manual counting of the length of the notes.  But note
> that this is NOT a cadenza in the sense of \cadenzaOn / \cadenzaOff, since
> it amounts to _metered_ music, while \cadenzaOn introduces an _unmetered_
> section.  Thus, the approach suggested is just a clever way of doing my
> example 3, isn't it?

If you follow Xavier's suggestion you can use the length of the
cadenza to set measureLength for the full-bar rest.  This will ensure
it's centred properly:

cadenzaRest =
#(define-music-function (parser location music) (ly:music?)
   "Make a full-bar rest with the same length as MUSIC
setting measureLength to ensure the rest is properly centred."
   (make-sequential-music
    (list
     (context-spec-music
      (make-property-set 'measureLength (ly:music-length music)) 'Timing)
     (mmrest-of-length music)
     (context-spec-music
      (make-property-unset 'measureLength) 'Timing))))

Cheers,
Neil



reply via email to

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