]> git.donarmstrong.com Git - lilypond.git/blob - ly/performer-init.ly
Make Score an initial Timing alias to allow for context mods
[lilypond.git] / ly / performer-init.ly
1 %%%% This file is part of LilyPond, the GNU music typesetter.
2 %%%%
3 %%%% Copyright (C) 1996--2012 Han-Wen Nienhuys <hanwen@xs4all.nl>
4 %%%%                          Jan Nieuwenhuizen <janneke@gnu.org>
5 %%%%
6 %%%% LilyPond is free software: you can redistribute it and/or modify
7 %%%% it under the terms of the GNU General Public License as published by
8 %%%% the Free Software Foundation, either version 3 of the License, or
9 %%%% (at your option) any later version.
10 %%%%
11 %%%% LilyPond is distributed in the hope that it will be useful,
12 %%%% but WITHOUT ANY WARRANTY; without even the implied warranty of
13 %%%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 %%%% GNU General Public License for more details.
15 %%%%
16 %%%% You should have received a copy of the GNU General Public License
17 %%%% along with LilyPond.  If not, see <http://www.gnu.org/licenses/>.
18
19 \version "2.14.0"
20
21 %%
22 %% setup for Request->Element conversion.
23 %%
24 \context {
25   \type "Performer_group"
26   \name Staff
27   \accepts Voice
28   \accepts CueVoice
29   \defaultchild Voice
30
31   \consists "Staff_performer"
32   \consists "Key_performer"
33 }
34 \context {
35   \name Global
36   \accepts Score
37   \description "Hard coded entry point for LilyPond.  Cannot be tuned."
38 }
39
40 \context {
41   \Staff
42   \name DrumStaff
43   midiInstrument = #"drums"
44   \accepts DrumVoice
45   \defaultchild DrumVoice
46 }
47
48 \context {
49   \type "Performer_group"
50   \name Voice
51   \consists "Dynamic_performer"
52   \consists "Tie_performer"
53   \consists "Piano_pedal_performer"
54   \consists "Note_performer"
55   \consists "Beam_performer"
56   \consists "Slur_performer"
57 }
58
59 \context {
60   \Voice
61   \name CueVoice
62   \alias Voice
63 }
64
65 \context {
66   \Voice
67   \name VaticanaVoice
68   \alias Voice
69 }
70
71 \context {
72   \Voice
73   \remove "Note_performer"
74   \consists "Drum_note_performer"
75   \name DrumVoice
76 }
77
78 \context {
79   \type "Performer_group"
80   \name FiguredBass
81 }
82
83 \context {
84   \type "Performer_group"
85   \name FretBoards
86 }
87
88 \context {
89   \type "Performer_group"
90   \name GrandStaff
91   \accepts RhythmicStaff
92   \accepts Staff
93   \accepts Dynamics
94   \defaultchild Staff
95 }
96
97 \context {
98   \type "Performer_group"
99   \name "PianoStaff"
100   \accepts Staff
101   \accepts DrumStaff
102   \defaultchild Staff
103 }
104
105 \context {
106   \Voice
107   \name TabVoice
108 }
109
110 \context {
111   \type "Performer_group"
112   \name "Devnull"
113 }
114
115 \context {
116   \Staff
117   \name TabStaff
118   midiInstrument = #"acoustic guitar (nylon)"
119   \alias Staff
120   \accepts TabVoice
121   \defaultchild TabVoice
122 }
123
124 \context {
125   \type "Performer_group"
126   \name "VaticanaStaff"
127   \alias "Staff"
128   \denies "Voice"
129   \accepts "VaticanaVoice"
130   \defaultchild "VaticanaVoice"
131 }
132
133 \context {
134   \type "Score_performer"
135
136   \name Score
137
138   melismaBusyProperties = #default-melisma-properties
139   instrumentName = #"bright acoustic"
140   midiChannelMapping = #'staff
141
142   %% quarter = 60
143   tempoWholesPerMinute = #(ly:make-moment 15 1)
144
145   \accepts Staff
146   \accepts DrumStaff
147   \accepts GrandStaff
148   \accepts PianoStaff
149   \accepts TabStaff
150   \accepts StaffGroup
151   \accepts Devnull
152   \accepts ChoirStaff
153   \accepts RhythmicStaff
154   \accepts ChordNames
155   \accepts FiguredBass
156   \accepts FretBoards
157   \accepts Lyrics
158   \accepts VaticanaStaff
159
160   \consists "Time_signature_performer"
161   \consists "Control_track_performer"
162   \consists "Tempo_performer"
163
164   \alias "Timing"
165
166   %% An alias for Timing is established by the Timing_translator in
167   %% whatever context it is initialized, and the timing variables are
168   %% then copied from wherever Timing had been previously established.
169   %% The alias at Score level provides a target for initializing
170   %% Timing variables in layout definitions before any
171   %% Timing_translator has been run.
172
173   timeSignatureFraction = #'(4 . 4)
174
175 %% These defaults should be the same as the rules established in
176 %%   scm/time-signature-settings.scm for 4/4 time
177   measureLength = #(ly:make-moment 4 4)
178   baseMoment = #(ly:make-moment 1  4)
179
180   \consists "Timing_translator"
181
182   \defaultchild "Staff"
183
184   dynamicAbsoluteVolumeFunction = #default-dynamic-absolute-volume
185   instrumentEqualizer = #default-instrument-equalizer
186   drumPitchTable = #(alist->hash-table midiDrumPitches)
187   timing = ##t
188 }
189
190
191 \context {
192   \type "Performer_group"
193   \consists "Staff_performer" % Performer_group ?
194   \consists "Lyric_performer"
195   \name Lyrics
196 }
197
198 \context{
199   \type "Performer_group"
200   \name ChoirStaff
201   \accepts Staff
202   \accepts DrumStaff
203   \defaultchild Staff
204 }
205
206 \context {
207   \type "Performer_group"
208   \consists "Staff_performer"
209   \accepts ChordNameVoice
210   \name ChordNames
211 }
212
213 \context {
214   \type "Performer_group"
215   \consists "Note_performer"
216   \name ChordNameVoice
217 }
218
219 \context {
220   \type "Performer_group"
221   \name StaffGroup
222   \accepts Staff
223   \accepts DrumStaff
224   \accepts TabStaff
225   \accepts RhythmicStaff
226   \accepts GrandStaff
227   \accepts PianoStaff
228   \accepts Lyrics
229   \accepts ChordNames
230   \accepts FiguredBass
231   \accepts FretBoards
232   \defaultchild Staff
233 }
234
235 \context {
236   \Staff
237   \name RhythmicStaff
238 }
239
240 \context {
241   \type "Performer_group"
242   \name Dynamics
243   \consists "Piano_pedal_performer"
244 }