]> git.donarmstrong.com Git - lilypond.git/blob - input/lsr/incipit.ly
Make the length of beamlets configurable.
[lilypond.git] / input / lsr / incipit.ly
1 %% Do not edit this file; it is auto-generated from input/new
2 %% This file is in the public domain.
3 \version "2.11.64"
4 \header {
5   texidoces = "
6 Los «incipit» se pueden escribir utilizando el grob del nombre del
7 instruemento, pero manteniendo independientes las definiciones del
8 nombre del instrumento y del incipit."
9  
10  doctitlees = "Incipit"
11
12   lsrtags = "staff-notation,ancient-notation"
13   texidoc = "Incipits can be added using the instrument name grob, but
14 keeping separate the instrument name definition and the incipit definition."
15   doctitle = "Incipit"
16 } % begin verbatim
17
18
19 incipit =
20 #(define-music-function (parser location incipit-music) (ly:music?)
21   #{
22     \once \override Staff.InstrumentName #'self-alignment-X = #RIGHT
23     \once \override Staff.InstrumentName #'self-alignment-Y = #UP
24     \once \override Staff.InstrumentName #'Y-offset = #4
25     \once \override Staff.InstrumentName #'padding = #0.3
26     \once \override Staff.InstrumentName #'stencil = 
27     #(lambda (grob)
28        (let* ((instrument-name (ly:grob-property grob 'long-text))
29               (layout (ly:output-def-clone (ly:grob-layout grob)))
30               (music (make-music 'SequentialMusic
31                       'elements (list (make-music 'ContextSpeccedMusic
32                                         'context-type 'MensuralStaff
33                                         'element (make-music 'PropertySet
34                                                    'symbol 'instrumentName
35                                                    'value instrument-name))
36                                       $incipit-music)))
37               (score (ly:make-score music))
38               (mm (ly:output-def-lookup layout 'mm))
39               (indent (ly:output-def-lookup layout 'indent))
40               (width (ly:output-def-lookup layout 'incipit-width))
41               (incipit-width (if (number? width)
42                                  (* width mm)
43                                  (* indent 0.5))))
44          (ly:output-def-set-variable! layout 'indent (- indent incipit-width))
45          (ly:output-def-set-variable! layout 'line-width indent)
46          (ly:output-def-set-variable! layout 'ragged-right #f)
47          (ly:output-def-set-variable! layout 'ragged-last #f)
48          (ly:output-def-set-variable! layout 'system-count 1)
49          (ly:score-add-output-def! score layout)
50          (set! (ly:grob-property grob 'long-text)
51                (markup #:score score))
52          (ly:system-start-text::print grob)))
53   #})
54
55 %%%%%%%%%%%%%%%%%%%%%%%%%
56
57 global = {
58   \set Score.skipBars = ##t
59   \key g \major
60   \time 4/4
61   
62   %make the staff lines invisible on staves
63   \override Staff.BarLine #'transparent = ##t
64   % the actual music
65   \skip 1*8
66
67   % let finis bar go through all staves
68   \override Staff.BarLine #'transparent = ##f
69
70   % finis bar
71   \bar "|."
72 }
73
74 discantusIncipit = <<
75   \new MensuralVoice = "discantusIncipit" <<
76     \repeat unfold 9 { s1 \noBreak }
77     {
78       \clef "neomensural-c1"
79       \key f \major
80       \time 2/2
81       c''1.
82     }
83   >>
84   \new Lyrics \lyricsto discantusIncipit { IV- }
85 >>
86
87 discantusNotes = {
88   \transpose c' c'' {
89     \clef "treble"
90     d'2. d'4 |
91     b e' d'2 |
92     c'4 e'4.( d'8 c' b |
93     a4) b a2 |
94     b4.( c'8 d'4) c'4 |
95     \once \override NoteHead #'transparent = ##t
96     c'1 |
97     b\breve |
98   }
99 }
100
101 discantusLyrics = \lyricmode {
102   Ju -- bi -- |
103   la -- te De -- |
104   o, om --
105   nis ter -- |
106   ra, __ om- |
107   "..." |
108   -us. |
109 }
110
111 altusIncipit = <<
112   \new MensuralVoice = "altusIncipit" <<
113     \repeat unfold 9 { s1 \noBreak }
114     {
115       \clef "neomensural-c3"
116       \key f \major
117       \time 2/2
118       r1 f'1.
119     }
120   >>
121   \new Lyrics \lyricsto altusIncipit { IV- }
122 >>
123
124 altusNotes = {
125   \transpose c' c'' {
126     \clef "treble"
127     % two measures
128     r2 g2. e4 fis g |
129     a2 g4 e |
130     fis g4.( fis16 e fis4) |
131     g1 |
132     \once \override NoteHead #'transparent = ##t
133     g1 |
134     g\breve |
135   }
136 }
137
138 altusLyrics = \lyricmode {
139   % two measures
140   Ju -- bi -- la -- te |
141   De -- o, om -- |
142   nis ter -- ra, |
143   "..." |
144   -us. |
145 }
146
147 tenorIncipit = <<
148   \new MensuralVoice = "tenorIncipit" <<
149     \repeat unfold 9 { s1 \noBreak }
150     {
151       \clef "neomensural-c4"
152       \key f \major
153       \time 2/2
154       r\longa
155       r\breve
156       r1 c'1.
157     }
158   >>
159   \new Lyrics \lyricsto tenorIncipit { IV- }
160 >>
161
162 tenorNotes = {
163   \transpose c' c' {
164     \once \override Staff.VerticalAxisGroup #'minimum-Y-extent = #'(-6 . 3)
165     \clef "treble_8"
166     R1 |
167     R1 |
168     R1 |
169     % two measures
170     r2 d'2. d'4 b e' |
171     \once \override NoteHead #'transparent = ##t
172     e'1 |
173     d'\breve |
174   }
175 }
176
177 tenorLyrics = \lyricmode {
178   % two measures
179   Ju -- bi -- la -- te |
180   "..." |
181   -us. 
182 }
183
184 bassusIncipit = <<
185   \new MensuralVoice = "bassusIncipit" <<
186     \repeat unfold 9 { s1 \noBreak }
187     {
188       \clef "bass"
189       \key f \major
190       \time 2/2
191       %% incipit
192       r\maxima
193       f1.
194     }
195   >>
196   \new Lyrics \lyricsto bassusIncipit { IV- }
197 >>
198
199 bassusNotes = {
200   \transpose c' c' {
201     \clef "bass"
202     R1 |
203     R1 |
204     R1 |
205     R1 |
206     g2. e4 |
207     \once \override NoteHead #'transparent = ##t
208     e1 |
209     g\breve |
210   }
211 }
212
213 bassusLyrics = \lyricmode {
214   Ju -- bi- |
215   "..." |
216   -us.
217 }
218
219 \score {
220   <<
221     \new StaffGroup = choirStaff <<
222       \new Voice = "discantusNotes" <<
223         \global
224         \set Staff.instrumentName = #"Discantus"
225         \incipit \discantusIncipit
226         \discantusNotes
227       >>
228       \new Lyrics = "discantusLyrics" \lyricsto discantusNotes { \discantusLyrics }
229       \new Voice = "altusNotes" <<
230         \global
231         \set Staff.instrumentName = #"Altus"
232         \incipit \altusIncipit
233         \altusNotes
234       >>
235       \new Lyrics = "altusLyrics" \lyricsto altusNotes { \altusLyrics }
236       \new Voice = "tenorNotes" <<
237         \global
238         \set Staff.instrumentName = #"Tenor"
239         \incipit \tenorIncipit
240         \tenorNotes
241       >>
242       \new Lyrics = "tenorLyrics" \lyricsto tenorNotes { \tenorLyrics }
243       \new Voice = "bassusNotes" <<
244         \global
245         \set Staff.instrumentName = #"Bassus"
246         \incipit \bassusIncipit
247         \bassusNotes
248       >>
249     >>
250     \new Lyrics = "bassusLyrics" \lyricsto bassusNotes { \bassusLyrics }
251     %% Keep the bass lyrics outside of the staff group to avoid bar lines
252     %% between the lyrics.
253   >>
254   \layout {
255     \context {
256       \Score
257       %% no bar lines in staves
258       \override BarLine #'transparent = ##t
259     }
260     %% the next three instructions keep the lyrics between the bar lines
261     \context {
262       \Lyrics
263       \consists "Bar_engraver" 
264       \override BarLine #'transparent = ##t
265     } 
266     \context {
267       \StaffGroup
268       \consists "Separating_line_group_engraver"
269     }
270     \context {
271       \Voice
272       %% no slurs
273       \override Slur #'transparent = ##t
274       %% Comment in the below "\remove" command to allow line
275       %% breaking also at those bar lines where a note overlaps
276       %% into the next measure.  The command is commented out in this
277       %% short example score, but especially for large scores, you
278       %% will typically yield better line breaking and thus improve
279       %% overall spacing if you comment in the following command.
280       %%\remove "Forbid_line_break_engraver"
281     }
282     indent = 6\cm
283     incipit-width = 4\cm
284   }
285 }