3 lsrtags = "staff-notation,ancient-notation"
4 texidoc = "Incipits can be added using the instrument name grob, but
5 keeping separate the instrument name definition and the incipit definition."
10 #(define-music-function (parser location incipit-music) (ly:music?)
12 \once \override Staff.InstrumentName #'self-alignment-X = #RIGHT
13 \once \override Staff.InstrumentName #'self-alignment-Y = #UP
14 \once \override Staff.InstrumentName #'Y-offset = #4
15 \once \override Staff.InstrumentName #'padding = #0.3
16 \once \override Staff.InstrumentName #'stencil =
18 (let* ((instrument-name (ly:grob-property grob 'long-text))
19 (layout (ly:output-def-clone (ly:grob-layout grob)))
20 (music (make-music 'SequentialMusic
21 'elements (list (make-music 'ContextSpeccedMusic
22 'context-type 'MensuralStaff
23 'element (make-music 'PropertySet
24 'symbol 'instrumentName
25 'value instrument-name))
27 (score (ly:make-score music))
28 (mm (ly:output-def-lookup layout 'mm))
29 (indent (ly:output-def-lookup layout 'indent))
30 (width (ly:output-def-lookup layout 'incipit-width))
31 (incipit-width (if (number? width)
34 (ly:output-def-set-variable! layout 'indent (- indent incipit-width))
35 (ly:output-def-set-variable! layout 'line-width indent)
36 (ly:output-def-set-variable! layout 'ragged-right #f)
37 (ly:output-def-set-variable! layout 'ragged-last #f)
38 (ly:output-def-set-variable! layout 'system-count 1)
39 (ly:score-add-output-def! score layout)
40 (set! (ly:grob-property grob 'long-text)
41 (markup #:score score))
42 (ly:system-start-text::print grob)))
45 %%%%%%%%%%%%%%%%%%%%%%%%%
48 \set Score.skipBars = ##t
52 %make the staff lines invisible on staves
53 \override Staff.BarLine #'transparent = ##t
57 % let finis bar go through all staves
58 \override Staff.BarLine #'transparent = ##f
65 \new MensuralVoice = "discantusIncipit" <<
66 \repeat unfold 9 { s1 \noBreak }
68 \clef "neomensural-c1"
74 \new Lyrics \lyricsto discantusIncipit { IV- }
85 \once \override NoteHead #'transparent = ##t
91 discantusLyrics = \lyricmode {
102 \new MensuralVoice = "altusIncipit" <<
103 \repeat unfold 9 { s1 \noBreak }
105 \clef "neomensural-c3"
111 \new Lyrics \lyricsto altusIncipit { IV- }
120 fis g4.( fis16 e fis4) |
122 \once \override NoteHead #'transparent = ##t
128 altusLyrics = \lyricmode {
130 Ju -- bi -- la -- te |
138 \new MensuralVoice = "tenorIncipit" <<
139 \repeat unfold 9 { s1 \noBreak }
141 \clef "neomensural-c4"
149 \new Lyrics \lyricsto tenorIncipit { IV- }
154 \once \override Staff.VerticalAxisGroup #'minimum-Y-extent = #'(-6 . 3)
161 \once \override NoteHead #'transparent = ##t
167 tenorLyrics = \lyricmode {
169 Ju -- bi -- la -- te |
175 \new MensuralVoice = "bassusIncipit" <<
176 \repeat unfold 9 { s1 \noBreak }
186 \new Lyrics \lyricsto bassusIncipit { IV- }
197 \once \override NoteHead #'transparent = ##t
203 bassusLyrics = \lyricmode {
211 \new StaffGroup = choirStaff <<
212 \new Voice = "discantusNotes" <<
214 \set Staff.instrumentName = #"Discantus"
215 \incipit \discantusIncipit
218 \new Lyrics = "discantusLyrics" \lyricsto discantusNotes { \discantusLyrics }
219 \new Voice = "altusNotes" <<
221 \set Staff.instrumentName = #"Altus"
222 \incipit \altusIncipit
225 \new Lyrics = "altusLyrics" \lyricsto altusNotes { \altusLyrics }
226 \new Voice = "tenorNotes" <<
228 \set Staff.instrumentName = #"Tenor"
229 \incipit \tenorIncipit
232 \new Lyrics = "tenorLyrics" \lyricsto tenorNotes { \tenorLyrics }
233 \new Voice = "bassusNotes" <<
235 \set Staff.instrumentName = #"Bassus"
236 \incipit \bassusIncipit
240 \new Lyrics = "bassusLyrics" \lyricsto bassusNotes { \bassusLyrics }
241 %% Keep the bass lyrics outside of the staff group to avoid bar lines
242 %% between the lyrics.
247 %% no bar lines in staves
248 \override BarLine #'transparent = ##t
250 %% the next three instructions keep the lyrics between the bar lines
253 \consists "Bar_engraver"
254 \override BarLine #'transparent = ##t
258 \consists "Separating_line_group_engraver"
263 \override Slur #'transparent = ##t
264 %% Comment in the below "\remove" command to allow line
265 %% breaking also at those bar lines where a note overlaps
266 %% into the next measure. The command is commented out in this
267 %% short example score, but especially for large scores, you
268 %% will typically yield better line breaking and thus improve
269 %% overall spacing if you comment in the following command.
270 %%\remove "Forbid_line_break_engraver"