]> git.donarmstrong.com Git - lilypond.git/blob - input/puer-fragment.ly
* GNUmakefile.in (local-WWW-post): move mutopia-index to toplevel
[lilypond.git] / input / puer-fragment.ly
1 \version "1.7.27"
2 \header {
3     title       = "Puer natus est nobis"
4     subtitle    = "Antiphona ad introitum VII"
5     texidoc = "
6
7 Demonstrate gregorian chant notation
8
9 This file pretty nicely demonstrates what still does
10 not work among ligatures: (i) horizontal spacing between ligatures and
11 lyrics aligment is broken; (ii) the clef does not show on each line;
12 (iii) lily crashes when removing Stem_engraver, but still using
13 Slur_engraver (this is useful needed for the \addlyrics feature when
14 no slurs are to be typeset); (iv) episem causes a parse error (this
15 used to work a while ago); (v) pitches are typeset half a staff space
16 too high (the second note is a d, but it appears on the line of the do
17 clef; this bug must have been introduced only recently); (vi) support
18 for augmentum dots is missing; (vii) accidentals must be placed before
19 the ligature (not demonstrated in this example)."
20
21 }
22
23 \include "paper26.ly"
24 \include "gregorian-init.ly"
25
26 %%% N.B.: Yes, I know, the formatting of the following looks awful,
27 %%% but this is intentional for editorial purposes (simplifies some
28 %%% global search/replace operations in emacs).
29
30 cantus = \notes \transpose c c {
31   \[ g4
32     (           %%% Pu-
33     \pes
34     d'-)
35   \]
36   d'            %%% er
37   \[ d'
38     (           %%% na-
39     \pes e' \flexa
40     d'-)
41   \]
42   c'            %%% tus
43   \[ c'
44     (           %%% est
45     c'
46     c'-)
47   \]
48   \[ d'
49     (           %%% no-
50     \flexa c' e' \flexa
51     d'
52     d'-)          %%% bis,
53   \]
54   \divisioMaior
55   \[ g
56     (           %%% et
57     \pes
58     d'-)
59   \]
60   \[ d'
61     (           %%% fi-
62     \pes e' \flexa
63     d'-)
64   \]
65   \[ c'
66     (           %%% li-
67     \flexa
68     b-)
69   \]
70   a             %%% us
71   \[ c'
72     (           %%% da-
73     c' \pes
74     d'-)
75   \]
76   c'            %%% tus-
77   c'            %%% est
78   \[ c'
79     (           %%% no-
80     \pes d' \flexa c'
81     c'-)
82   \]
83   \[ g
84     (           %%% bis:
85     \pes a \flexa
86     g-)
87   \]
88   \divisioMaxima
89   g             %%% cu-
90   a             %%% us
91   c'            %%% im-
92   \[ b
93     (           %%% pe-
94     \pes d' e' \pes
95     f'-)
96   \]
97   \[ d'
98     (           %%% ri-
99     \flexa
100     c'-)
101   \]
102   c'            %%% um
103 }
104
105 verba = \context Lyrics = verba \lyrics {
106   Pu- er na- tus est no- bis,
107   et fi- li- us da- tus est no- bis:
108   cu- ius im- pe- ri- um
109 }
110
111 \score {
112   \context StaffGroup <
113     \context VaticanaStaff <
114       \context VaticanaVoice <
115         \addlyrics
116         \cantus
117         \verba
118       >
119     >
120   >
121   \paper {
122     stafflinethickness = \staffspace / 5.0
123     linewidth = 137.0\mm
124     width = 137.0\mm
125     indent = 0.0
126     raggedright = ##t
127     packed = ##t
128 %   width = 15.0 \cm %%% no effect?
129
130     \translator {
131       \VoiceContext
132       \name VaticanaVoice
133       \alias Voice
134
135       % Can not `\remove "Slur_engraver"', since \addlyrics needs
136       % slurs working.  Hence, set slurs transparent instead.
137       Slur \override #'transparent = ##t
138
139       % N.B.: Warnings of the type "Degenerate bow: infinite steepness
140       % reqd" arise from the fact that all noteheads of a ligature are
141       % in the same paper column.  Therefore, the (transparent) slurs
142       % often start and end in the same column, producing the above
143       % warning.  TODO: supress this warning; we need slurs only for
144       % \addlyrics, not for printing.
145
146       % `\remove "Stem_engraver"' currently produces a crash (see
147       % below).  Hence, set stems transparent instead.
148       Stem \set #'transparent = ##t
149       % \remove "Stem_engraver"
150
151 %{
152
153 FIXME:
154
155 When removing Stem_engraver from VoiceContext (but still using
156 Slur_engraver), lily will crash while trying to typeset slurs, since
157 `()' is not a valid stem:
158
159 In unknown file:
160    ?: 0* [Slur::after_line_breaking #<Grob Slur >]
161    ?: 1* [#<procedure #f (slur dir)> #<Grob Slur > -1]
162 In /home/reuter/project/lilypond-1.7/share/lilypond/scm/slur.scm:
163   43: 2* [not ...
164   43: 3*  [attached-to-stem #<Grob Slur > -1]
165   10: 4   (let* ((note-columns #) (col #) (stem #)) (and (eq? col #) stem ...))
166     ...
167   16: 5   [ly:get-grob-property () heads]
168
169 /home/reuter/project/lilypond-1.7/share/lilypond/scm/slur.scm:16:6: In procedure ly_get_grob_property in expression (ly:get-grob-property stem (quote heads)):
170 /home/reuter/project/lilypond-1.7/share/lilypond/scm/slur.scm:16:6: Wrong type argument in position 1 (expecting grob): ()
171
172 %}
173
174       \remove Ligature_bracket_engraver
175       \consists Vaticana_ligature_engraver
176       NoteHead \set #'style = #'vaticana_punctum
177       Script \set #'padding = #0.0
178
179       % prepare TextSpanner for \episem{Initium|Finis} use
180       TextSpanner \set #'style = #'line
181       TextSpanner \set #'edge-height = #'(0 . 0)
182       TextSpanner \set #'padding = #0.5
183       TextSpanner \set #'edge-text = #'("" . "")
184     }
185     \translator {
186       \VoiceContext
187       \name GregorianTransciptionVoice
188       \alias Voice
189       Stem \set #'transparent = ##t
190       % \remove "Stem_engraver"
191       % Slur \override #'transparent = ##t
192       \remove "Slur_engraver"
193     }
194     \translator {
195       \StaffContext
196       \name GregorianTranscriptionStaff
197       \alias Staff
198       \accepts GregorianTranscriptionVoice
199       BarLine \override #'transparent = ##t
200     }
201     \translator {
202       \StaffContext
203       \name VaticanaStaff
204       \alias Staff
205       \accepts VaticanaVoice
206       \remove Bar_engraver
207       \consists Custos_engraver
208       clefGlyph = #"clefs-vaticana_do"
209       centralCPosition = #0
210       clefPosition = #1
211       clefOctavation = #0
212       StaffSymbol \set #'line-count = #4
213       StaffSymbol \set #'width = #60.0 % FIXME: unit should be \linewidth
214       TimeSignature \set #'transparent = ##t
215       KeySignature \set #'style = #'vaticana
216       Accidental \set #'style = #'vaticana
217       Custos \set #'style = #'vaticana
218       Custos \set #'neutral-position = #3
219       Custos \set #'neutral-direction = #-1
220       Custos \set #'adjust-if-on-staffline = ##t
221     }
222     \translator {
223       \HaraKiriStaffContext
224       \accepts VaticanaVoice
225       \accepts GregorianTranscriptionVoice
226     }
227     \translator {
228       \ScoreContext
229       \accepts VaticanaStaff
230       \accepts GregorianTranscriptionStaff
231       \remove Bar_number_engraver
232 %      SpacingSpanner \set #'spacing-increment = #0.5
233       timing = ##f
234
235       % Don't do this except for transcription -- it will produce
236       % additional space
237       barAlways = ##t
238 %      skipBars = ##t
239     }
240   }
241 }