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