]> git.donarmstrong.com Git - lilypond.git/blob - input/test/part-combine-score.ly
patch::: 1.3.134.jcn1
[lilypond.git] / input / test / part-combine-score.ly
1
2 \header {
3 texidoc="Template for part-combining orchestral scores";
4 }
5   
6 \include "paper16.ly"; 
7 % \include "mutopia/Coriolan/coriolan-paper.ly";
8
9 #(define text-flat '((font-relative-size . -2 ) (music "accidentals--1")))
10
11 End = { \skip 1*9; \bar "|."; }
12
13 flautoI = \notes\relative c'' {
14   c4\pp d e f
15   b,4 d c d
16   r2 e4 f
17   \break
18   \context Score \outputproperty #(make-type-checker 'paper-column-interface)
19   #'between-system-string = #"\\eject"
20
21   c4 d e f
22   c4 r e f
23   c4 r e f
24   \break
25   c4 r a r
26   a a r a
27   a2 \property VoiceCombineThread.soloADue = ##f a
28 }
29
30 flautoII = \notes\relative c'' {
31   g4\ff b d f
32   r2 c4 d
33   a c c d
34   a4. b8 c4 d
35   c r e r
36   r2 s2
37   a,4 r a r
38   a r r a
39   a2 \property VoiceCombineThread.soloADue = ##f a
40 }
41           
42 flautiStaff =  \notes \context VoiceCombineStaff = flauti <
43   \property VoiceCombineStaff.midiInstrument = #"flute"
44 %  \property VoiceCombineStaff.instrument = #"2 Flauti"
45 %  \property VoiceCombineStaff.instr = #"Fl."
46
47   \property VoiceCombineStaff.instrument = #`((kern . 0.5) (lines
48     "2 Clarinetti" (rows "(B" ,text-flat ")")))
49
50   \property VoiceCombineStaff.instr = #`((kern . 0.5) (lines
51     "Cl."  (rows "(B" ,text-flat ")")))
52
53   %\global
54   \context VoiceCombineVoice=one \partcombine VoiceCombineVoice
55     \context VoiceCombineThread=one \flautoI
56     \context VoiceCombineThread=two \flautoII
57 >
58
59 legniGroup =  \context StaffGroup = legni_group <
60   \flautiStaff
61   %\oboiStaff
62   %\clarinettiStaff
63   %\fagottiStaff
64 >
65
66 violinoI = \notes\relative c'' {
67   c4 d e f
68   c d e f
69   c d e f
70   c d e f
71   c d e f
72   c d e f
73   c4 d e f
74   a8 a a a b b b b
75   d1
76 }      
77
78 violinoII = \notes\relative c'' { 
79   c4 d e f
80   c d e f
81   c d e f
82   c2 e2
83   c4 d e f
84   c2 e2
85   c,4 d e f
86   a8 a a a b b b b
87   b1
88 }
89
90 violinoIStaff =  \context Staff = oneViolini <
91  \property Staff.midiInstrument = #"violin"
92   \property Staff.instrument = #"Violino I"
93   \property Staff.instr = #"Vl. I"
94   \violinoI
95   \End
96 >
97
98 violinoIIStaff =  \context Staff = twoViolini <
99   % MIDI hoort geeneens verschil tussen een
100   % eerste en tweede viool ;-)
101   \property Staff.midiInstrument = #"violin"
102   \property Staff.instrument = #"Violino II"
103   \property Staff.instr = #"Vl. II"
104   \violinoII
105   \End
106 >
107
108 violaI = \notes\transpose c, \violinoI
109
110 violaII = \notes\transpose c, \violinoII
111
112 violeGroup =  \notes \context VoiceCombineStaff = oneViole <
113   \property VoiceCombineStaff.midiInstrument = #"viola"
114   \property VoiceCombineStaff.instrument = #"Viola"
115   \property VoiceCombineStaff.instr = #"Vla."
116   %\clef "alto";
117   % Ugh, clef broken in 1.3.125
118   \property VoiceCombineStaff.clefGlyph = #"clefs-C"
119   \property VoiceCombineStaff.clefPosition = #0
120   \key f \major;
121   \End
122
123   \context VoiceCombineVoice=oneViole \partcombine VoiceCombineVoice
124     \context VoiceCombineThread=oneViole \violaI
125     \context VoiceCombineThread=twoViole \violaII
126 >
127
128 violoncello = \notes\relative c {
129   c1\ff d e f c d e f c
130 }
131
132 contrabasso = \notes\relative c {
133   c1\pp
134   d4 e d e
135   e1
136   f4 g f g
137   c1
138   d4 e d e
139   e1
140   f4 g f g
141   c1
142 }
143
144
145 bassiGroup =  \context PianoStaff = bassi_group \notes <
146   \context StaffCombineStaff=oneBassi {
147     \property StaffCombineStaff.midiInstrument = #"cello"
148
149     % Ugh, markup burps
150     \property StaffCombineStaff.instrument = #'((kern . 0.5)
151     (lines "Violoncello" (rows "    e") (rows "Contrabasso")))
152
153     \property StaffCombineStaff.instr = #"Vc."
154     
155     %\clef "bass";
156     % Ugh, clef broken in 1.3.125
157     \property StaffCombineStaff.clefGlyph = #"clefs-F"
158     \property StaffCombineStaff.clefPosition = #2
159
160     \key es \major;
161     \End
162   }
163   \context StaffCombineStaff=twoBassi {
164     \property StaffCombineStaff.midiInstrument = #"contrabass"
165     \property StaffCombineStaff.instrument = #"Contrabasso"
166     \property StaffCombineStaff.instr = #"Cb."
167     
168     %\clef "bass";
169     % Ugh, clef broken in 1.3.125
170     \property StaffCombineStaff.clefGlyph = #"clefs-F"
171     \property StaffCombineStaff.clefPosition = #2
172     
173     \key as \major;
174     \End
175   }
176
177   \context StaffCombineStaff=oneBassi \partcombine StaffCombineStaff
178     \context StaffCombineVoice=oneBassi \violoncello
179     \context StaffCombineVoice=twoBassi \contrabasso
180 >
181
182
183 violiniGroup =  \context GrandStaff = violini_group <
184   \violinoIStaff
185   \violinoIIStaff
186 >
187
188 archiGroup =  \context StaffGroup = archi_group <
189   \violiniGroup
190   \violeGroup
191   \bassiGroup
192 >
193
194
195 \score{
196   <
197     \legniGroup
198     %\ottoniGroup
199     %\timpaniGroup
200     \archiGroup
201   >
202   \header {
203     title = "Coriolan";
204     subtitle = "Ouverture"; 
205     opus = "Opus 62";
206     composer = "Ludwig van Beethoven (1770-1827)";
207     enteredby = "JCN";
208     copyright = "public domain";
209   }
210   \paper{
211     \paperSixteen
212
213     %textheight = 290.0\mm;
214     %linewidth = 195.0\mm;
215     textheight = 285.0\mm;
216     linewidth = 190.0\mm;
217
218     \translator{ \HaraKiriStaffContext }
219     %
220     % The Voice combine hierarchy
221     %
222     \translator{
223       \ThreadContext
224       \name "VoiceCombineThread";
225       \consists "Rest_engraver";
226     }
227     \translator{
228       \VoiceContext
229       \name "VoiceCombineVoice";
230       soloText = #"I."
231       soloIIText = #"II."
232       \remove "Rest_engraver";
233       \accepts "VoiceCombineThread";
234     }
235     \translator{
236       \HaraKiriStaffContext
237       \consists "Mark_engraver";
238       \name "VoiceCombineStaff";
239       \accepts "VoiceCombineVoice";
240     }
241
242     %
243     % The Staff combine hierarchy
244     %
245     \translator{
246       \ThreadContext
247       \name "StaffCombineThread";
248     }
249     \translator{
250       \VoiceContext
251       \name "StaffCombineVoice";
252       \accepts "StaffCombineThread";
253       \consists "Thread_devnull_engraver";
254     }
255     \translator {
256       \HaraKiriStaffContext
257       \name "StaffCombineStaff";
258       \accepts "StaffCombineVoice";
259
260       soloADue = ##t
261       soloText = #""
262       soloIIText = #""
263       % This is non-conventional, but currently it is
264       % the only way to tell the difference.
265       aDueText = #"\\`a2"
266       splitInterval = #'(1 . 0)
267       changeMoment = #`(,(make-moment 1 1) . ,(make-moment 1 1))
268     }
269     \translator {
270       \StaffGroupContext
271       \accepts "VoiceCombineStaff";
272       \accepts "StaffCombineStaff";
273     }
274     \translator{ \HaraKiriStaffContext }
275
276     \translator {
277       %\ScoreContext
278       \OrchestralScoreContext
279       \accepts "VoiceCombineStaff";
280       \accepts "StaffCombineStaff";
281       TimeSignature \override #'style = #'C
282       skipBars = ##t 
283       BarNumber \override #'padding = #3
284       RestCollision \override #'maximum-rest-count = #1
285     }
286   }
287 }