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