]> git.donarmstrong.com Git - lilypond.git/blob - ly/engraver-init.ly
Second set of volta changes (Issue 2673)
[lilypond.git] / ly / engraver-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.15.39"
20
21 \context {
22   \name "Global"
23
24   \accepts "Score"
25
26   \defaultchild "Score"
27   \description "Hard coded entry point for LilyPond.  Cannot be tuned."
28   \grobdescriptions #all-grob-descriptions
29   EventClasses = #all-event-classes
30 }
31
32 \context {
33   \type "Engraver_group"
34   \name "FretBoards"
35   \alias "Staff"
36   \description "A context for displaying fret diagrams."
37
38   \consists "Fretboard_engraver"
39   \consists "Output_property_engraver"
40   \consists "Hara_kiri_engraver"
41   \consists "Separating_line_group_engraver"
42   \consists "Font_size_engraver"
43   \consists "Instrument_name_engraver"
44
45   %% explicitly set instrument, so it is not inherited from the parent
46   instrumentName = #'()
47   shortInstrumentName = #'()
48
49   predefinedDiagramTable = #default-fret-table
50   handleNegativeFrets = #'recalculate
51   restrainOpenStrings = ##f
52 }
53
54 \context {
55   \type "Engraver_group"
56   \name "Staff"
57
58   \consists "Output_property_engraver"
59   \consists "Bar_engraver"
60   \consists "Pure_from_neighbor_engraver"
61   %% Bar_engraver must be first so default bars aren't overwritten
62   %% with empty ones.
63
64   \consists "Font_size_engraver"
65   \consists "Separating_line_group_engraver"
66   \consists "Dot_column_engraver"
67   \consists "Staff_collecting_engraver"
68
69  %% perhaps move to Voice context?
70   \consists "Ottava_spanner_engraver"
71   \consists "Clef_engraver"
72   \consists "Key_engraver"
73   \consists "Time_signature_engraver"
74   \consists "Ledger_line_engraver"
75   \consists "Staff_symbol_engraver"
76   \consists "Collision_engraver"
77   \consists "Grob_pq_engraver"
78   \consists "Rest_collision_engraver"
79   \consists "Accidental_engraver"
80   \consists "Piano_pedal_engraver"
81   \consists "Piano_pedal_align_engraver"
82   \consists "Instrument_name_engraver"
83   \consists "Axis_group_engraver"
84   \consists "Figured_bass_engraver"
85   \consists "Figured_bass_position_engraver"
86   \consists "Script_row_engraver"
87   \consists "Cue_clef_engraver"
88   \consists "Footnote_engraver"
89
90   localKeySignature = #'()
91   createSpacing = ##t
92   ignoreFiguredBassRest = ##f
93
94   %% explicitly set instrument, so we don't get
95   %% weird effects when doing instrument names for
96   %% piano staves
97   instrumentName = #'()
98   shortInstrumentName = #'()
99
100   \defaultchild "Voice"
101   \accepts "Voice"
102   \accepts "CueVoice"
103
104   \description "Handles clefs, bar lines, keys, accidentals.  It can contain
105 @code{Voice} contexts."
106
107 }
108
109 \context {
110   \Staff
111   \type "Engraver_group"
112   \name "DrumStaff"
113   \alias "Staff"
114
115   \remove "Accidental_engraver"
116   \remove "Ottava_spanner_engraver"
117   \remove "Key_engraver"
118   \remove "Piano_pedal_engraver"
119
120   \description "Handles typesetting for percussion."
121
122   \denies "Voice"
123   \accepts "DrumVoice"
124   \defaultchild "DrumVoice"
125
126   clefGlyph = #"clefs.percussion"
127   clefPosition = #0
128   \override Script #'staff-padding = #0.75
129 }
130
131
132 \context {
133   \type "Engraver_group"
134   \name "ChoirStaff"
135   \consists "Vertical_align_engraver"
136   topLevelAlignment = ##f
137
138   \consists "Instrument_name_engraver"
139   \consists "System_start_delimiter_engraver"
140   systemStartDelimiter = #'SystemStartBracket
141   %% explicitly set instrument, so it is not inherited from the parent
142   instrumentName = #'()
143   shortInstrumentName = #'()
144   vocalName = #'()
145   shortVocalName = #'()
146
147   \accepts "Staff"
148   \accepts "DrumStaff"
149   \accepts "RhythmicStaff"
150   \accepts "GrandStaff"
151   \accepts "PianoStaff"
152   \accepts "Lyrics"
153   \accepts "ChordNames"
154   \accepts "FiguredBass"
155   \accepts "ChoirStaff"
156   \accepts "StaffGroup"
157   \defaultchild "Staff"
158   \description "Identical to @code{StaffGroup} except that the
159 contained staves are not connected vertically."
160 }
161
162 \context{
163   \type "Engraver_group"
164
165   localKeySignature = #'()
166   createSpacing = ##t
167
168   squashedPosition = #0
169   \name RhythmicStaff
170   \alias "Staff"
171
172   \override BarLine #'bar-extent = #'(-2 . 2)
173   \override VoltaBracket #'staff-padding = #3
174   \override StaffSymbol #'line-count = #1
175
176   \override Stem  #'neutral-direction = #UP
177   \override Beam  #'neutral-direction = #UP
178
179   \consists "Output_property_engraver"
180   \consists "Font_size_engraver"
181   \consists "Separating_line_group_engraver"
182   \consists "Dot_column_engraver"
183   \consists "Bar_engraver"
184   \consists "Staff_symbol_engraver"
185   \consists "Pitch_squash_engraver"
186   \consists "Time_signature_engraver"
187   \consists "Instrument_name_engraver"
188   \consists "Axis_group_engraver"
189   \consists "Ledger_line_engraver"
190
191   %% explicitly set instrument, so it is not inherited from the parent
192   instrumentName = #'()
193   shortInstrumentName = #'()
194
195   \accepts "Voice"
196   \accepts "CueVoice"
197   \defaultchild "Voice"
198
199   \description "A context like @code{Staff} but for printing rhythms.
200 Pitches are ignored; the notes are printed on one line."
201 }
202
203
204 \context {
205   \type "Engraver_group"
206   \name "Voice"
207
208   \description "Corresponds to a voice on a staff.  This context
209 handles the conversion of dynamic signs, stems, beams, super- and
210 subscripts, slurs, ties, and rests.
211
212 You have to instantiate this explicitly if you want to have
213 multiple voices on the same staff."
214
215   \consists "Font_size_engraver"
216
217   \consists "Pitched_trill_engraver"
218   \consists "Output_property_engraver"
219   \consists "Arpeggio_engraver"
220   \consists "Multi_measure_rest_engraver"
221   \consists "Text_spanner_engraver"
222   \consists "Trill_spanner_engraver"
223   \consists "Grob_pq_engraver"
224   \consists "Forbid_line_break_engraver"
225   \consists "Laissez_vibrer_engraver"
226   \consists "Repeat_tie_engraver"
227   \consists "Note_head_line_engraver"
228   \consists "Glissando_engraver"
229   \consists "Ligature_bracket_engraver"
230   \consists "Breathing_sign_engraver"
231   \consists "Note_heads_engraver"
232   \consists "Dots_engraver"
233   \consists "Rest_engraver"
234   \consists "Tweak_engraver"
235
236   %% switch on to make stem directions interpolate for the
237   %% center line.
238   %  \consists "Melody_engraver"
239
240   \consists "Stem_engraver"
241   \consists "Beam_engraver"
242   \consists "Grace_beam_engraver"
243   \consists "Auto_beam_engraver"
244
245   %% must come before Script_column_engraver.
246   \consists "New_fingering_engraver"
247
248   \consists "Chord_tremolo_engraver"
249   \consists "Double_percent_repeat_engraver"
250   \consists "Percent_repeat_engraver"
251   \consists "Slash_repeat_engraver"
252   \consists "Part_combine_engraver"
253
254   \consists "Text_engraver"
255   \consists "New_dynamic_engraver"
256   \consists "Dynamic_align_engraver"
257 %  \consists "Dynamic_engraver"
258   \consists "Fingering_engraver"
259   \consists "Bend_engraver"
260
261   \consists "Script_engraver"
262   \consists "Script_column_engraver"
263   \consists "Rhythmic_column_engraver"
264   \consists "Note_spacing_engraver"
265   \consists "Spanner_break_forbid_engraver"
266   \consists "Phrasing_slur_engraver"
267   \consists "Cluster_spanner_engraver"
268   \consists "Slur_engraver"
269   \consists "Tie_engraver"
270   \consists "Tuplet_engraver"
271   \consists "Grace_engraver"
272   \consists "Instrument_switch_engraver"
273 }
274
275 \context{
276   \Voice
277
278   \name CueVoice
279   \alias Voice
280   fontSize = #-4
281   \override Stem #'length-fraction = #(magstep -4)
282   \override Beam #'length-fraction = #(magstep -4)
283   \override Beam #'beam-thickness = #0.35
284 }
285
286 \context {
287   \Voice
288   \name DrumVoice
289   \alias Voice
290
291   \description "A voice on a percussion staff."
292   \remove "Arpeggio_engraver"
293   \consists "Grob_pq_engraver"
294
295   \remove "Note_head_line_engraver"
296   \remove "Glissando_engraver"
297   \remove "Ligature_bracket_engraver"
298   \remove "Note_heads_engraver"
299   \consists "Drum_notes_engraver"
300   \remove "New_fingering_engraver"
301
302   \remove "Fingering_engraver"
303
304   \remove "Cluster_spanner_engraver"
305 }
306
307 \context{
308   \type "Engraver_group"
309   \name GrandStaff
310   localKeySignature = #'()
311
312   \description "A group of staves, with a brace on the left
313 side, grouping the staves together.  The bar lines of the
314 contained staves are connected vertically."
315
316   \consists "Instrument_name_engraver"
317   \consists "Span_bar_engraver"
318   \consists "Span_bar_stub_engraver"
319   \consists "Span_arpeggio_engraver"
320   \consists "System_start_delimiter_engraver"
321   \consists "Vertical_align_engraver"
322   systemStartDelimiter = #'SystemStartBrace
323   topLevelAlignment = ##f
324   %% explicitly set instrument, so it is not inherited from the parent
325   instrumentName = #'()
326   shortInstrumentName = #'()
327
328   \defaultchild "Staff"
329   \accepts "Staff"
330   \accepts "RhythmicStaff"
331   \accepts "DrumStaff"
332   \accepts "TabStaff"
333   \accepts "Lyrics"
334   \accepts "FiguredBass"
335   \accepts "Dynamics"
336   \accepts "ChordNames"
337 }
338
339 \context{
340   \GrandStaff
341   \name "PianoStaff"
342   \alias "GrandStaff"
343
344   \description "Just like @code{GrandStaff}, but the staves are only removed
345 together, never separately."
346
347   \consists "Vertical_align_engraver"
348   \consists "Keep_alive_together_engraver"
349   topLevelAlignment = ##f
350
351   instrumentName = #'()
352   shortInstrumentName = #'()
353 }
354
355 \context {
356   \type "Engraver_group"
357   \name "StaffGroup"
358
359   \consists "Vertical_align_engraver"
360   topLevelAlignment = ##f
361
362   \consists "Instrument_name_engraver"
363   \consists "Span_bar_engraver"
364   \consists "Span_bar_stub_engraver"
365   \consists "Span_arpeggio_engraver"
366   \consists "Output_property_engraver"
367   systemStartDelimiter = #'SystemStartBracket
368   %% explicitly set instrument, so it is not inherited from the parent
369   instrumentName = #'()
370   shortInstrumentName = #'()
371
372   \consists "System_start_delimiter_engraver"
373
374   \defaultchild "Staff"
375   \accepts "Staff"
376   \accepts "RhythmicStaff"
377   \accepts "DrumStaff"
378   \accepts "GrandStaff"
379   \accepts "PianoStaff"
380   \accepts "TabStaff"
381   \accepts "Lyrics"
382   \accepts "ChordNames"
383   \accepts "FiguredBass"
384   \accepts "ChoirStaff"
385   \accepts "StaffGroup"
386
387   \description "Groups staves while adding a bracket on the left
388 side, grouping the staves together.  The bar lines of the contained
389 staves are connected vertically.  @code{StaffGroup} only consists of
390 a collection of staves, with a bracket in front and spanning bar lines."
391 }
392
393 \context {
394   \type "Engraver_group"
395   \name Dynamics
396   \alias Voice
397   \consists "Output_property_engraver"
398   \consists "Bar_engraver"
399   \consists "Piano_pedal_engraver"
400   \consists "Script_engraver"
401   \consists "New_dynamic_engraver"
402   \consists "Dynamic_align_engraver"
403   \consists "Text_engraver"
404   \consists "Text_spanner_engraver"
405   \consists "Axis_group_engraver"
406   \consists "Tweak_engraver"
407
408   pedalSustainStrings = #'("Ped." "*Ped." "*")
409   pedalUnaCordaStrings = #'("una corda" "" "tre corde")
410   \override VerticalAxisGroup #'staff-affinity = #CENTER
411   \override VerticalAxisGroup #'nonstaff-relatedstaff-spacing =
412     #'((basic-distance . 5)
413        (padding . 0.5))
414   \override TextScript #'font-shape = #'italic
415   \override DynamicLineSpanner #'Y-offset = #0
416   \override DynamicText #'X-offset =
417   #(ly:make-simple-closure
418     `(,+
419       ,(ly:make-simple-closure
420          (list ly:self-alignment-interface::centered-on-note-columns))
421       ,(ly:make-simple-closure
422         (list ly:self-alignment-interface::x-aligned-on-self))))
423
424   \description "Holds a single line of dynamics, which will be
425 centered between the staves surrounding this context."
426 }
427
428
429 \context{
430   \type "Engraver_group"
431
432   \description "Corresponds to a voice with lyrics.  Handles the
433 printing of a single line of lyrics."
434
435   \name "Lyrics"
436   \consists "Lyric_engraver"
437   \consists "Extender_engraver"
438   \consists "Hyphen_engraver"
439   \consists "Tweak_engraver"
440   \consists "Stanza_number_engraver"
441   \consists "Instrument_name_engraver"
442   \consists "Font_size_engraver"
443   \consists "Hara_kiri_engraver"
444   \consists "Pure_from_neighbor_engraver"
445   searchForVoice = ##f
446   %% explicitly set instrument, so it is not inherited from the parent
447   instrumentName = #'()
448   shortInstrumentName = #'()
449
450   \override VerticalAxisGroup #'remove-first = ##t
451   \override VerticalAxisGroup #'remove-empty = ##t
452   \override VerticalAxisGroup #'staff-affinity = #UP
453   \override VerticalAxisGroup #'nonstaff-relatedstaff-spacing =
454     #'((basic-distance . 5.5)
455        (padding . 0.5)
456        (stretchability . 1))
457   \override VerticalAxisGroup #'nonstaff-nonstaff-spacing =
458      #'((basic-distance . 0)
459         (minimum-distance . 2.8)
460         (padding . 0.2)
461         (stretchability . 0))
462   \override VerticalAxisGroup #'nonstaff-unrelatedstaff-spacing #'padding = #1.5
463   \override InstrumentName #'self-alignment-Y = ##f
464
465   %% sync with define-grobs.scm ;
466   \override InstrumentName #'font-size = #1.0
467
468   %% make sure that barlines aren't collapsed, when
469   %% Bar_engraver is there.
470   \override BarLine #'bar-extent = #'(-0.05 . 0.05)
471
472 }
473
474 \context {
475   \type "Engraver_group"
476   \name NoteNames
477   \description "A context for printing the names of notes."
478   \consists "Axis_group_engraver"
479
480   \override VerticalAxisGroup #'staff-affinity = #UP
481   \override VerticalAxisGroup #'nonstaff-nonstaff-spacing =
482     #'((basic-distance . 0)
483        (minimum-distance . 2.8)
484        (padding . 0.2)
485        (stretchability . 0))
486   \override VerticalAxisGroup #'nonstaff-relatedstaff-spacing =
487     #'((basic-distance . 5.5)
488        (padding . 0.5)
489        (stretchability . 1))
490   \override VerticalAxisGroup
491     #'nonstaff-unrelatedstaff-spacing #'padding = 1.5
492
493   \consists "Tie_engraver"
494   \consists "Note_name_engraver"
495   \consists "Separating_line_group_engraver"
496 }
497
498 \context {
499   \type "Engraver_group"
500   \name ChordNames
501   \description "Typesets chord names."
502
503   \consists "Output_property_engraver"
504   \consists "Separating_line_group_engraver"
505   \consists "Chord_name_engraver"
506   \consists "Hara_kiri_engraver"
507 %  \consists "Note_spacing_engraver"
508   \override VerticalAxisGroup #'remove-first = ##t
509   \override VerticalAxisGroup #'remove-empty = ##t
510   \override VerticalAxisGroup #'staff-affinity = #DOWN
511   \override VerticalAxisGroup #'nonstaff-relatedstaff-spacing #'padding = #0.5
512   \override VerticalAxisGroup #'nonstaff-nonstaff-spacing #'padding = #0.5
513 }
514
515 \context {
516   \type "Score_engraver"
517   \name "Score"
518
519   \description "This is the top level notation context.  No
520 other context can contain a @code{Score} context.  This context
521 handles the administration of time signatures.  It also makes sure
522 that items such as clefs, time signatures, and key-signatures are
523 aligned across staves.
524
525 You cannot explicitly instantiate a @code{Score} context (since it
526 is not contained in any other context).  It is instantiated
527 automatically when an output definition (a @code{\score} or
528 @code{\layout} block) is processed."
529
530   \consists "Paper_column_engraver"
531   \consists "Repeat_acknowledge_engraver"
532   \consists "Staff_collecting_engraver"
533
534   \alias "Timing"
535
536   %% An alias for Timing is established by the Timing_translator in
537   %% whatever context it is initialized, and the timing variables are
538   %% then copied from wherever Timing had been previously established.
539   %% The alias at Score level provides a target for initializing
540   %% Timing variables in layout definitions before any
541   %% Timing_translator has been run.
542
543   % timing translator must come BEFORE bar number engraver
544   \consists "Timing_translator"
545   \consists "Default_bar_line_engraver"
546   \consists "Output_property_engraver"
547   \consists "System_start_delimiter_engraver"
548   \consists "Mark_engraver"
549   \consists "Volta_engraver"
550   \consists "Metronome_mark_engraver"
551   \consists "Break_align_engraver"
552   \consists "Spacing_engraver"
553   \consists "Grace_spacing_engraver"
554   \consists "Vertical_align_engraver"
555   \consists "Stanza_number_align_engraver"
556   \consists "Bar_number_engraver"
557   \consists "Parenthesis_engraver"
558   \consists "Concurrent_hairpin_engraver"
559   \consists "Beam_collision_engraver"
560   \consists "Footnote_engraver"
561
562   \defaultchild "Staff"
563
564   \accepts "FretBoards"
565   \accepts "Staff"
566   \accepts "RhythmicStaff"
567   \accepts "TabStaff"
568   \accepts "VaticanaStaff"
569   \accepts "GregorianTranscriptionStaff"
570   \accepts "MensuralStaff"
571   \accepts "PetrucciStaff"
572   \accepts "StaffGroup"
573   \accepts "DrumStaff"
574   \accepts "KievanStaff"
575   \accepts "Lyrics"
576   \accepts "ChordNames"
577   \accepts "GrandStaff"
578   \accepts "ChoirStaff"
579   \accepts "PianoStaff"
580   \accepts "Devnull"
581   \accepts "NoteNames"
582   \accepts "FiguredBass"
583
584   noteToFretFunction = #determine-frets
585   predefinedDiagramTable = ##f
586   soloText = #"Solo"
587   soloIIText = #"Solo II"
588   aDueText = #"a2"
589   printPartCombineTexts = ##t
590   partCombineTextsOnNote = ##t
591   systemStartDelimiter =#'SystemStartBar
592
593   drumStyleTable = #drums-style
594
595   melismaBusyProperties = #default-melisma-properties
596   tieWaitForNote = ##f
597   clefGlyph = #"clefs.G"
598   clefPosition = #-2
599   middleCClefPosition = #-6
600   middleCPosition = #-6
601   firstClef = ##t
602
603   crescendoSpanner = #'hairpin
604   decrescendoSpanner = #'hairpin
605
606   defaultBarType = #"|"
607   doubleRepeatType = #":|:"
608   startRepeatType = #"|:"
609   endRepeatType = #":|"
610   barNumberVisibility = #first-bar-number-invisible-and-no-parenthesized-bar-numbers
611   barNumberFormatter = #robust-bar-number-function
612   automaticBars = ##t
613
614   explicitClefVisibility = #all-visible
615   explicitCueClefVisibility = #end-of-line-invisible
616   explicitKeySignatureVisibility = #all-visible
617   implicitTimeSignatureVisibility = #end-of-line-invisible
618
619   repeatCountVisibility = #all-repeat-counts-visible
620
621   voltaAllowEndLineOnGlyphs = #'(
622     ":|" "|:" "||:" "|." ":|:" ":|.|:" ":|.:" ".|" 
623     "S|:" ":|S" ":|S." ".S|:" ":|S|:" ":|S.|:" )
624
625   timeSignatureSettings = #default-time-signature-settings
626   timeSignatureFraction = 4/4
627
628 %% These defaults should be the same as the rules established in
629 %%   scm/time-signature-settings.scm for 4/4 time
630   measureLength = #(ly:make-moment 4 4)
631   baseMoment = #(ly:make-moment 1  4)
632   beatStructure = #'(1 1 1 1)
633   beamExceptions = #'((end . (((1 . 8) . (4 4))
634                               ((1 . 12) . (3 3 3 3)))))
635   beamHalfMeasure = ##t
636
637   autoBeaming = ##t
638   autoBeamCheck = #default-auto-beam-check
639
640   scriptDefinitions = #default-script-alist
641
642   pedalSustainStrings = #'("Ped." "*Ped." "*")
643   pedalSustainStyle = #'text
644   pedalUnaCordaStrings = #'("una corda" "" "tre corde")
645   pedalUnaCordaStyle = #'text
646
647 %% These are in ordinary italic font, including the *,
648 %% but they are unlikely to be used,
649 %% as the default pedal-style for SostenutoPedal is 'mixed':
650 %% i.e.  Sost. Ped_____________________
651   pedalSostenutoStrings = #'("Sost. Ped." "*Sost. Ped." "*")
652   pedalSostenutoStyle = #'mixed
653
654   harmonicAccidentals = ##t
655   fingeringOrientations = #'(up down)
656   stringNumberOrientations = #'(up down)
657   strokeFingerOrientations = #'(right)
658
659   lyricMelismaAlignment = #LEFT
660   markFormatter = #format-mark-letters
661   rehearsalMark = #1
662   subdivideBeams = ##f
663   extraNatural = ##t
664   autoAccidentals = #`(Staff ,(make-accidental-rule 'same-octave 0))
665   autoCautionaries = #'()
666
667   printKeyCancellation = ##t
668   keyAlterationOrder = #`(
669     (6 . ,FLAT) (2  . ,FLAT) (5 . ,FLAT ) (1  . ,FLAT) (4  . ,FLAT) (0  . ,FLAT) (3  . ,FLAT)
670     (3 . ,SHARP) (0 . ,SHARP) (4 . ,SHARP) (1 . ,SHARP) (5 . ,SHARP) (2 . ,SHARP) (6 . ,SHARP)
671     (6 . ,DOUBLE-FLAT) (2 . ,DOUBLE-FLAT) (5 . ,DOUBLE-FLAT ) (1 . ,DOUBLE-FLAT) (4 . ,DOUBLE-FLAT) (0 . ,DOUBLE-FLAT) (3 . ,DOUBLE-FLAT)
672     (3  . ,DOUBLE-SHARP) (0 . ,DOUBLE-SHARP) (4 . ,DOUBLE-SHARP) (1 . ,DOUBLE-SHARP) (5 . ,DOUBLE-SHARP) (2 . ,DOUBLE-SHARP) (6 . ,DOUBLE-SHARP)
673   )
674
675   barCheckSynchronize = ##f
676
677 %% chord names:
678   chordNameFunction = #ignatzek-chord-names
679   minorChordModifier = #(make-simple-markup "m")
680   additionalPitchPrefix = #"" % was "add"
681   majorSevenSymbol = #whiteTriangleMarkup
682   chordNameLowercaseMinor = ##f
683   chordNameSeparator = #(make-hspace-markup 0.5)
684   slashChordSeparator = #(make-simple-markup "/")
685   chordNameExceptions = #ignatzekExceptions
686   chordNoteNamer = #'()
687   chordRootNamer = #note-name->markup
688   chordPrefixSpacer = #0
689   chordNameExceptionsFull = #fullJazzExceptions
690   chordNameExceptionsPartial = #partialJazzExceptions
691   noChordSymbol = #(make-simple-markup "N.C.")
692
693   bassStaffProperties = #'((assign clefGlyph "clefs.F")
694   (assign clefPosition 2)
695   (assign middleCPosition 6)
696   (assign middleCClefPosition 6))
697 %% tablature:
698   stringOneTopmost = ##t
699   highStringOne = ##t
700
701 %% One may change the string tunings as follows :
702 %% The length of the list must be equal to the number of strings
703   stringTunings = #guitar-tuning
704   tablatureFormat = #fret-number-tablature-format
705   tabStaffLineLayoutFunction = #tablature-position-on-lines
706
707 %%
708   figuredBassFormatter = #format-bass-figure
709   metronomeMarkFormatter = #format-metronome-markup
710
711
712   %% See also make-voice-props-set
713   graceSettings = #`(
714     (Voice Stem direction ,UP)
715     (Voice Stem font-size -3)
716     (Voice Flag font-size -3)
717     (Voice NoteHead font-size -3)
718     (Voice TabNoteHead font-size -4)
719     (Voice Dots font-size -3)
720     (Voice Stem length-fraction 0.8)
721     (Voice Stem no-stem-extend #t)
722     (Voice Beam beam-thickness 0.384)
723     (Voice Beam length-fraction 0.8)
724     (Voice Accidental font-size -4)
725     (Voice AccidentalCautionary font-size -4)
726     (Voice Slur direction ,DOWN)
727     (Voice Script font-size -3)
728     (Voice Fingering font-size -8)
729     (Voice StringNumber font-size -8)
730   )
731
732   keepAliveInterfaces = #'(
733     bass-figure-interface
734     chord-name-interface
735     cluster-beacon-interface
736     fret-diagram-interface
737     lyric-syllable-interface
738     note-head-interface
739     tab-note-head-interface
740     lyric-interface
741     percent-repeat-item-interface
742     percent-repeat-interface
743
744     ;; need this, as stanza numbers are items, and appear only once.
745     stanza-number-interface
746   )
747   % \quoteDuring is supposed to quote everything, cueDuring only the essentials
748   quotedEventTypes = #'(StreamEvent)
749   quotedCueEventTypes = #'(
750     note-event
751     rest-event
752     tie-event
753     beam-event
754     tuplet-span-event)
755   instrumentTransposition = #(ly:make-pitch 0 0 0)
756
757   topLevelAlignment = ##t
758
759   timing = ##t
760 }
761
762
763
764
765 \context {
766   \type "Engraver_group"
767   \name "FiguredBass"
768   \description "A context for printing a figured bass line."
769
770   \consists "Figured_bass_engraver"
771   \consists "Separating_line_group_engraver"
772   \consists "Hara_kiri_engraver"
773
774   \override VerticalAxisGroup #'remove-empty = ##t
775   \override VerticalAxisGroup #'remove-first = ##t
776   \override VerticalAxisGroup #'staff-affinity = #UP
777   \override VerticalAxisGroup #'nonstaff-relatedstaff-spacing #'padding = #0.5
778   \override VerticalAxisGroup #'nonstaff-nonstaff-spacing #'padding = #0.5
779 }
780
781 \context {
782   \name "Devnull"
783   \type "Engraver_group"
784
785 %% don't want to route anything out of here:
786   \alias "Staff"
787   \alias "Voice"
788   \description "Silently discards all musical information given to this
789 context."
790 }
791
792 \context {
793   \Voice
794   \name "TabVoice"
795   \alias "Voice"
796   \consists "Tab_note_heads_engraver"
797   \consists "Tab_tie_follow_engraver"
798
799   \remove "Note_heads_engraver"
800   \remove "Fingering_engraver"
801   \remove "New_fingering_engraver"
802   \remove "Pitched_trill_engraver"
803
804   \description "Context for drawing notes in a Tab staff."
805
806   %% TabStaff increase the staff-space, which in turn
807   %% increases beam thickness and spacing; beams are
808   %% too big. We have to adjust the beam settings:
809   \override Beam #'beam-thickness = #0.32
810   \override Beam #'length-fraction = #0.62
811   %% the same goes for tremolo beams
812   \override StemTremolo #'beam-thickness = #0.32
813   %% NOTE: in lily/stem-tremolo.cc, we have length-fraction = 1,
814   %% and the tablature staff space is scaled (1.5 by default),
815   %% so we use the inversion of the scale factor:
816   \override StemTremolo #'length-fraction = #(lambda (grob)
817                                                (/ 1 (ly:staff-symbol-staff-space grob)))
818   \override StemTremolo #'beam-width = #stem-tremolo::calc-tab-width
819
820   %% No accidental in tablature !
821   \remove "Accidental_engraver"
822   %% make the Stems as short as possible to minimize their influence
823   %% on the slur::calc-control-points routine
824   \override Stem #'no-stem-extend = ##t
825   \override Flag #'style = #'no-flag
826   \override Stem #'details = #'((lengths 0 0 0 0 0 0)
827                                 (beamed-lengths 0 0 0)
828                                 (beamed-minimum-free-lengths 0 0 0)
829                                 (beamed-extreme-minimum-free-lengths 0 0)
830                                 (stem-shorten 0 0))
831   %% after all, the stubs of the stems may still be visible, so ...
832   \override Stem #'stencil = ##f
833   \override Flag #'stencil = ##f
834   %% automatic beams should be suppressed for similar reasons ...
835   autoBeaming = ##f
836   %% remove beams, dots and rests ...
837   \override Beam #'stencil = ##f
838   \override StemTremolo #'stencil = ##f
839   \override Dots #'stencil = ##f
840   \override Rest #'stencil = ##f
841   \override MultiMeasureRest #'stencil = ##f
842   \override MultiMeasureRestNumber #'stencil = ##f
843   \override MultiMeasureRestText #'stencil = ##f
844   %% ... all kinds of ties/slurs
845   \override Tie  #'stencil = ##f
846   \override RepeatTie #'stencil = ##f
847   \override LaissezVibrerTie #'stencil = ##f
848   \override Slur #'stencil = #slur::draw-tab-slur
849   \override PhrasingSlur #'stencil = ##f
850   %% 'tied to' fret numbers become invisible or parenthesized, respectively)
851   \override Tie #'after-line-breaking = #tie::handle-tab-note-head
852   \override RepeatTie #'after-line-breaking = #repeat-tie::handle-tab-note-head
853   %% ... and all kinds of markups, spanners etc.
854   \override TupletBracket #'stencil = ##f
855   \override TupletNumber #'stencil = ##f
856   \override DynamicText #'stencil = ##f
857   \override DynamicTextSpanner #'stencil = ##f
858   \override TextSpanner #'stencil = ##f
859   \override Hairpin #'stencil = ##f
860   \override Script #'stencil = ##f
861   \override TextScript #'stencil = ##f
862   \override Glissando #'stencil = #glissando::draw-tab-glissando
863   %% the direction for glissando lines will be automatically corrected
864   \override Glissando #'extra-dy = #glissando::calc-tab-extra-dy
865   \override Glissando #'bound-details #'right = #`((attach-dir . ,LEFT)
866                                                    (padding . 0.3))
867   \override Glissando #'bound-details #'left = #`((attach-dir . ,RIGHT)
868                                                    (padding . 0.3))
869   %% dead notes
870   \override TabNoteHead #'glyph-name = #tab-note-head::calc-glyph-name
871   \override TabNoteHead #'stencil = #tab-note-head::whiteout-if-style-set
872 }
873
874 \context {
875   \Staff
876   \alias "Staff"
877   \name "TabStaff"
878   \denies "Voice"
879   \consists "Tab_staff_symbol_engraver"
880
881   \description "Context for generating tablature. It accepts only @code{TabVoice}
882 contexts and handles the line spacing, the tablature clef etc. properly."
883
884   \accepts "TabVoice"
885   \defaultchild "TabVoice"
886
887   %% 6 strings, bigger spacing
888   \override StaffSymbol #'staff-space = #1.5
889
890   %% Don't draw stems over the tablature figures !
891   \override Stem #'avoid-note-head = ##t
892
893   %% No accidental in tablature !
894   \remove "Accidental_engraver"
895   \remove "Key_engraver"
896
897   \remove "Ottava_spanner_engraver"
898   %% the clef handler
899   \override Clef #'stencil = #clef::print-modern-tab-if-set
900   %% no time signature
901   \override TimeSignature #'stencil = ##f
902   %% no arpeggios
903   \override Arpeggio #'stencil = ##f
904   %% we ignore collision warnings that may occur due to
905   %% stem overlapping, because we have no stems ;-)
906   \override NoteColumn #'ignore-collision = ##t
907   %% Special "TAB" clef
908   clefGlyph = #"clefs.tab"
909   clefPosition = #0
910   %% Change string if note results in negative fret number
911   handleNegativeFrets = #'recalculate
912   %% Allow open strings even if minimumFret is set
913   restrainOpenStrings = ##f
914 }
915
916 \context {
917   \Voice
918   \name "VaticanaVoice"
919   \alias "Voice"
920   \description "Same as @code{Voice} context, except that it is
921 accommodated for typesetting Gregorian Chant in the notational style
922 of Editio Vaticana."
923
924   \remove "Slur_engraver"
925   \remove "Stem_engraver"
926   \remove "Ligature_bracket_engraver"
927   \consists "Vaticana_ligature_engraver"
928   \remove "Text_spanner_engraver"
929   \consists "Episema_engraver"
930
931   %% Set default head for notes outside of \[ \].
932   \override NoteHead #'style = #'vaticana.punctum
933
934   %% Put some space before and after divisiones.
935   %% FIXME: This does not seem to show any effect.
936   \override Script #'padding = #0.5
937
938   %% There are no beams in Gregorian Chant notation.
939   autoBeaming = ##f
940 }
941
942 \context {
943   \Staff
944   \name "VaticanaStaff"
945   \alias "Staff"
946   \denies "Voice"
947   \accepts "VaticanaVoice"
948   \defaultchild "VaticanaVoice"
949
950   \description "Same as @code{Staff} context, except that it is
951 accommodated for typesetting Gregorian Chant in the notational style
952 of Editio Vaticana."
953
954   \remove "Time_signature_engraver"
955   \consists "Custos_engraver"
956
957   %% We can not remove Bar_engraver; otherwise clefs and custodes will
958   %% not show up any more among other line breaking issues.
959   %% Instead, we make the grob transparent.
960   \override BarLine #'transparent = ##t
961
962   \override StaffSymbol #'line-count = #4
963   \override StaffSymbol #'thickness = #0.6
964
965   %% FIXME: unit on StaffSymbol's width should be \linewidth.
966   %% \override StaffSymbol #'width = #60.0
967
968   %% Choose vaticana do clef on 3rd line as default.
969   clefGlyph = #"clefs.vaticana.do"
970   middleCPosition = #1
971   middleCClefPosition = #1
972   clefPosition = #1
973   clefOctavation = #0
974
975   %% Select vaticana style font.
976   \override KeySignature #'glyph-name-alist = #alteration-vaticana-glyph-name-alist
977   \override Accidental #'glyph-name-alist = #alteration-vaticana-glyph-name-alist
978   \override Custos #'style = #'vaticana
979   \override Custos #'neutral-position = #3
980   \override Custos #'neutral-direction = #DOWN
981   \override Dots #'style = #'vaticana
982 }
983
984 \context {
985   \Voice
986   \name "GregorianTranscriptionVoice"
987   \alias "Voice"
988   \consists "Episema_engraver"
989
990   %% Removing ligature bracket engraver without replacing it by some
991   %% other ligature engraver would cause a "Junking event: `LigatureEvent'"
992   %% warning for every "\[" and "\]".  Therefore, we make the grob
993   %% transparent instead.
994   \override LigatureBracket #'transparent = ##t
995
996   %% Put some space before and after divisiones.
997   %% FIXME: This does not seem to show any effect.
998   \override Script #'padding = #0.5
999
1000   %% There are no beams in Gregorian Chant notation.
1001   autoBeaming = ##f
1002
1003 }
1004
1005 \context {
1006   \Staff
1007   \name "GregorianTranscriptionStaff"
1008   \alias "Staff"
1009   \denies "Voice"
1010   \accepts "GregorianTranscriptionVoice"
1011   \defaultchild "GregorianTranscriptionVoice"
1012
1013   %% We can not remove Bar_engraver; otherwise clefs and custodes will
1014   %% not show up any more among other line breaking issues.
1015   %% Instead, we make the grob transparent.
1016   \override BarLine #'transparent = ##t
1017 }
1018
1019 \context {
1020   \Voice
1021   \name "MensuralVoice"
1022   \alias "Voice"
1023   \description "Same as @code{Voice} context, except that it is
1024 accommodated for typesetting a piece in mensural style."
1025
1026   \remove "Slur_engraver"
1027   \remove "Ligature_bracket_engraver"
1028   \consists "Mensural_ligature_engraver"
1029
1030   %% Set default head for notes outside of \[ \].
1031   \override NoteHead #'style = #'mensural
1032   \override Rest #'style = #'mensural
1033   \override Flag #'style = #'mensural
1034
1035   %% There are no beams in mensural notation.
1036   autoBeaming = ##f
1037 }
1038
1039 \context {
1040   \Staff
1041   \name "MensuralStaff"
1042   \alias "Staff"
1043   \denies "Voice"
1044   \defaultchild "MensuralVoice"
1045   \accepts "MensuralVoice"
1046   \description "Same as @code{Staff} context, except that it is
1047 accommodated for typesetting a piece in mensural style."
1048
1049   \consists "Custos_engraver"
1050
1051   %% We can not remove Bar_engraver; otherwise clefs and custodes will
1052   %% not show up any more among other line breaking issues.
1053   %% Instead, we make the grob transparent.
1054   \override BarLine #'transparent = ##t
1055
1056   \override StaffSymbol #'thickness = #0.6
1057
1058   %% FIXME: unit on StaffSymbol's width should be \linewidth.
1059   %% \override StaffSymbol #'width = #60.0
1060
1061   %% Choose mensural g clef on 2nd line as default.
1062   clefGlyph = #"clefs.mensural.g"
1063   middleCClefPosition = #-6
1064   middleCPosition = #-6
1065   clefPosition = #-2
1066   clefOctavation = #0
1067
1068   %% Select mensural style font.
1069   \override TimeSignature #'style = #'mensural
1070   \override KeySignature #'glyph-name-alist = #alteration-mensural-glyph-name-alist
1071   \override Accidental #'glyph-name-alist = #alteration-mensural-glyph-name-alist
1072   \override Custos #'style = #'mensural
1073   \override Custos #'neutral-position = #3
1074   \override Custos #'neutral-direction = #DOWN
1075
1076   %% Accidentals are valid only once (same as
1077   %% \accidentalStyle "forget")
1078   extraNatural = ##f
1079   autoAccidentals = #`(Staff ,(make-accidental-rule 'same-octave -1))
1080   autoCautionaries = #'()
1081   printKeyCancellation = ##f
1082 }
1083
1084 \context {
1085   \Voice
1086   \name "PetrucciVoice"
1087   \alias "Voice"
1088   \description "Same as @code{Voice} context, except that it is
1089 accommodated for typesetting a piece in Petrucci style."
1090
1091   \remove "Ligature_bracket_engraver"
1092   \consists "Mensural_ligature_engraver"
1093
1094   %% Set glyph styles.
1095   \override NoteHead #'style = #'petrucci
1096   \override Rest #'style = #'mensural
1097
1098   % Thickens and shortens stems.
1099   \override Stem #'thickness = #1.7
1100   \override Stem #'length = #5
1101
1102   %% There are no beams in Petrucci notation.
1103   autoBeaming = ##f
1104 }
1105
1106 \context {
1107   \Staff
1108   \name "PetrucciStaff"
1109   \alias "Staff"
1110   \denies "Voice"
1111   \defaultchild "PetrucciVoice"
1112   \accepts "PetrucciVoice"
1113   \description "Same as @code{Staff} context, except that it is
1114 accommodated for typesetting a piece in Petrucci style."
1115
1116   \consists "Custos_engraver"
1117
1118   \override StaffSymbol #'thickness = #1.3
1119
1120   %% Choose Petrucci g clef on 2nd line as default.
1121   clefGlyph = #"clefs.petrucci.g"
1122   middleCClefPosition = #-6
1123   middleCPosition = #-6
1124   clefPosition = #-2
1125   clefOctavation = #0
1126
1127   \override Custos #'style = #'mensural
1128   \override Custos #'neutral-position = #3
1129   \override Custos #'neutral-direction = #DOWN
1130
1131   %% Accidentals are valid only once (if the following note is different)
1132   extraNatural = ##f
1133   autoAccidentals = #`(Staff ,(make-accidental-rule 'same-octave 0)
1134                              ,neo-modern-accidental-rule)
1135   autoCautionaries = #'()
1136   printKeyCancellation = ##f
1137 }
1138
1139 \context {
1140  \Voice
1141  \name "KievanVoice"
1142  \alias "Voice"
1143  \description "Same as @code{Voice} context, except that it is
1144 accommodated for typesetting a piece in Kievan style."
1145
1146  %% Set glyph styles.
1147  \override NoteHead #'style = #'kievan
1148  \override Rest #'style = #'mensural
1149  \override Accidental #'glyph-name-alist = #alteration-kievan-glyph-name-alist
1150  \override Dots #'style = #'kievan
1151  \override Slur #'stencil = ##f
1152
1153  %% There are beams in Kievan notation, but they are invoked manually
1154  autoBeaming = ##f
1155 }
1156
1157 \context {
1158  \Staff
1159  \name "KievanStaff"
1160  \alias "Staff"
1161  \denies "Voice"
1162  \defaultchild "KievanVoice"
1163  \accepts "KievanVoice"
1164  \description "Same as @code{Staff} context, except that it is
1165 accommodated for typesetting a piece in Kievan style."
1166
1167  \remove "Time_signature_engraver"
1168
1169  %% Choose Kievan tsefaut clef
1170  clefGlyph = #"clefs.kievan.do"
1171  middleCClefPosition = #0
1172  middleCPosition = #0
1173  clefPosition = #0
1174  clefOctavation = #0
1175
1176  %% Accidentals are valid only once (if the following note is different)
1177  extraNatural = ##f
1178  autoAccidentals = #`(Staff ,(make-accidental-rule 'same-octave 0)
1179                             ,neo-modern-accidental-rule)
1180  autoCautionaries = #'()
1181  printKeyCancellation = ##f
1182
1183 }
1184
1185 %% Keep the old definitions in here for compatibility (they erase previous
1186 %% settings to the corresponding context!).
1187 %% For new scores, one should simply insert the \RemoveEmptyStaves settings
1188 %% into the desired context. That's just as easy, requires only one line more
1189 %% (the \*Staff), but preserves previous context mods.
1190 %% TODO: DEPRECATED_2.13.17, remove at some point in the future
1191 RemoveEmptyStaffContext = \context {
1192   \Staff
1193   \RemoveEmptyStaves
1194 }
1195
1196 AncientRemoveEmptyStaffContext = \context {
1197   \VaticanaStaff
1198   \RemoveEmptyStaves
1199 }
1200
1201 RemoveEmptyDrumStaffContext = \context {
1202   \DrumStaff
1203   \RemoveEmptyStaves
1204 }
1205
1206 RemoveEmptyRhythmicStaffContext = \context {
1207   \RhythmicStaff
1208   \RemoveEmptyStaves
1209 }
1210
1211 RemoveEmptyTabStaffContext = \context {
1212   \TabStaff
1213   \RemoveEmptyStaves
1214 }