lilypond-user
[Top][All Lists]
Advanced

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

Re: Automatically numbering "instrument name"?


From: Manuela Gößnitzer
Subject: Re: Automatically numbering "instrument name"?
Date: Wed, 9 Aug 2017 06:34:30 +0200

Do you mean something like this?

#(define score-number 0) %% insert in first score

#(set! score-number (1+ score-number))

 \new PianoStaff \with {
    instrumentName = \markup {
 #(number->string score-number) "."
    }
  }
\relative c'' { c }


2017-08-08 23:33 GMT+02:00 Sam Bivens <address@hidden>:
As I finish up a sight-singing course packet, I'm wondering if it's possible for LilyPond to automatically number the individual scores from beginning to end.

Throughout the document, I have six different types of score contexts, shown in mwe.ly.

The perfect solution would be a fix where LilyPond automatically creates a `\with { instrumentName = "1. " }`, where the "1." here becomes dynamic and adjusts depending on the ordering of the score samples within the document.

Perhaps there is only a solution where we can insert a variable that will increase by one at every occurrence. If so, this is sufficient; I can write my own script to insert all necessary `instrumentName = "var"` entries.

Thanks,

Sam

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



reply via email to

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