6 % setup for Request->Element conversion. Guru-only
9 StaffContext=\translator {
10 \type "Engraver_group_engraver"
13 \description "Handles clefs, bar lines, keys, accidentals. It can contain
14 @code{Voice} contexts."
17 \consists "Output_property_engraver"
19 \consists "Bar_engraver"
20 % Bar_engraver must be first so default bars aren't overwritten
22 \consists "Font_size_engraver"
24 % \consists "Repeat_engraver"
25 \consists "Volta_engraver"
26 \consists "Separating_line_group_engraver"
27 SeparatingGroupSpanner \override #'spacing-procedure
28 = #Separating_group_spanner::set_spacing_rods_and_seqs
29 \consists "Dot_column_engraver"
31 % perhaps move to Voice context?
32 \consists "Ottava_spanner_engraver"
33 \consists "Clef_engraver"
34 \consists "Key_engraver"
35 \consists "Time_signature_engraver"
36 \consists "Staff_symbol_engraver"
37 \consists "Collision_engraver"
38 \consists "Rest_collision_engraver"
39 \consists "Accidental_engraver"
40 \consists "Piano_pedal_engraver"
41 \consists "Instrument_name_engraver"
42 \consists "Grob_pq_engraver"
43 \consists "Forbid_line_break_engraver"
44 \consistsend "Axis_group_engraver"
46 minimumVerticalExtent = #'(-6 . 6)
47 extraVerticalExtent = ##f
49 localKeySignature = #'()
51 % explicitly set instrument, so we don't get
52 % weird effects when doing instrument names for
62 StaffContainerContext = \translator {
63 \type Engraver_group_engraver
64 \consists "Axis_group_engraver"
65 minimumVerticalExtent = ##f
66 extraVerticalExtent = ##f
68 localKeySignature = #'()
74 InnerChoirStaffContext = \translator {
75 \type "Engraver_group_engraver"
77 \consists "System_start_delimiter_engraver"
78 systemStartDelimiter = #'SystemStartBracket
79 localKeySignature = #'()
82 \accepts "RhythmicStaff"
89 ChoirStaffContext = \translator {
90 \InnerChoirStaffContext
93 \description "Identical to @code{StaffGroup} except that the
94 contained staves are not connected vertically."
96 \accepts "InnerChoirStaff"
97 \accepts "InnerStaffGroup"
101 RhythmicStaffContext=\translator{
102 \type "Engraver_group_engraver"
104 \consists "Output_property_engraver"
107 A context like @code{Staff} but for printing rhythms. Pitches are
108 ignored; the notes are printed on one line.
110 minimumVerticalExtent = ##f
111 extraVerticalExtent = ##f
113 localKeySignature = #'()
115 \consists "Pitch_squash_engraver"
116 \consists "Separating_line_group_engraver"
120 BarLine \override #'bar-size = #4
121 VoltaBracket \override #'minimum-space = #15 % urg, in \pt
122 VoltaBracket \override #'padding = #5 % urg, in \pt
123 StaffSymbol \override #'line-count = #1
125 Stem \override #'neutral-direction = #1
126 Beam \override #'neutral-direction = #1
127 % \consists "Repeat_engraver"
128 \consists "Dot_column_engraver"
129 \consists "Volta_engraver"
130 \consists "Bar_engraver"
131 \consists "Time_signature_engraver"
132 \consists "Staff_symbol_engraver"
133 \consists "Instrument_name_engraver"
134 \consistsend "Axis_group_engraver"
139 VoiceContext = \translator {
140 \type "Engraver_group_engraver"
144 Corresponds to a voice on a staff. This context handles the
145 conversion of dynamic signs, stems, beams, super- and subscripts,
146 slurs, ties, and rests.
148 You have to instantiate this explicitly if you want to have
149 multiple voices on the same staff."
151 localKeySignature = #'()
152 \consists "Font_size_engraver"
154 % must come before all
155 \consists "Voice_devnull_engraver"
156 \consists "Output_property_engraver"
157 \consists "Arpeggio_engraver"
158 \consists "Multi_measure_rest_engraver"
159 \consists "Text_spanner_engraver"
160 \consists "Grob_pq_engraver"
162 \consists "Note_head_line_engraver"
163 \consists "Glissando_engraver"
164 \consists "Ligature_bracket_engraver"
165 \consists "Breathing_sign_engraver"
166 % \consists "Rest_engraver"
167 \consists "Stem_engraver"
168 \consists "Beam_engraver"
169 \consists "Grace_beam_engraver"
170 \consists "Auto_beam_engraver"
171 \consists "New_fingering_engraver"
172 \consists "Chord_tremolo_engraver"
173 \consists "Percent_repeat_engraver"
174 \consists "Slash_repeat_engraver"
175 \consists "Melisma_engraver"
178 Must come before text_engraver, but after note_column engraver.
181 \consists "Text_engraver"
182 \consists "Dynamic_engraver"
183 \consists "Fingering_engraver"
185 \consists "Script_engraver"
186 \consists "Script_column_engraver"
187 \consists "Rhythmic_column_engraver"
188 \consists "Phrasing_slur_engraver"
189 \consists "Cluster_spanner_engraver"
190 \consists "Slur_engraver"
191 \consists "Tie_engraver"
192 \consists "New_tie_engraver"
193 \consists "Tuplet_engraver"
194 \consists "A2_engraver"
196 \consists "Skip_event_swallow_translator"
197 \accepts Thread % bug if you leave out this!
200 ThreadContext = \translator{
201 \type Engraver_group_engraver
203 localKeySignature = #'()
205 Handles note heads, and is contained in the Voice context. You
206 have to instantiate this explicitly if you want to adjust the
207 style of individual note heads.
209 \consists "Font_size_engraver"
210 \consists "Thread_devnull_engraver"
211 \consists "Note_heads_engraver"
212 \consists "Rest_engraver"
215 \consists "Output_property_engraver"
221 GrandStaffContext=\translator{
222 \type "Engraver_group_engraver"
224 localKeySignature = #'()
226 \description " A group of staffs, with a brace on the left
227 side, grouping the staves together. The bar lines of the
228 contained staves are connected vertically. "
230 \consists "Span_bar_engraver"
231 \consists "Span_arpeggio_engraver"
232 \consists "System_start_delimiter_engraver"
233 systemStartDelimiter = #'SystemStartBrace
238 PianoStaffContext = \translator{
243 Just like @code{GrandStaff} but with @code{minVerticalAlign} set
244 equal to @code{maxVerticalAlign} so that interstaff beaming and
245 slurring can be used."
246 verticalAlignmentChildCallback = #Align_interface::fixed_distance_alignment_callback
247 VerticalAlignment \override #'forced-distance = #12
248 VerticalAlignment \override #'self-alignment-Y = #0
250 \consists "Vertical_align_engraver"
251 \consists "Instrument_name_engraver"
256 % \consistsend "Axis_group_engraver"
259 InnerStaffGroupContext= \translator {
260 \type "Engraver_group_engraver"
261 \name InnerStaffGroup
262 localKeySignature = #'()
264 \consists "Span_bar_engraver"
265 \consists "Span_arpeggio_engraver"
266 \consists "Output_property_engraver"
267 systemStartDelimiter = #'SystemStartBracket
269 \consists "System_start_delimiter_engraver"
271 \accepts "RhythmicStaff"
272 \accepts "GrandStaff"
273 \accepts "PianoStaff"
276 \accepts "ChordNames"
279 StaffGroupContext = \translator {
280 \InnerStaffGroupContext
285 " Groups staffs while adding a bracket on the left side,
286 grouping the staves together. The bar lines of the contained
287 staves are connected vertically.
290 \accepts "InnerChoirStaff"
291 \accepts "ChoirStaff"
292 \accepts "InnerStaffGroup"
293 \accepts "FiguredBass"
298 LyricsVoiceContext= \translator{
299 \type "Engraver_group_engraver"
300 \consistsend "Hara_kiri_engraver"
301 minimumVerticalExtent = #'(-1.2 . 2.4)
302 extraVerticalExtent = ##f
306 Corresponds to a voice with lyrics. Handles the printing of a
307 single line of lyrics.
311 \consists "Separating_line_group_engraver"
312 \consists "Lyric_engraver"
313 \consists "Extender_engraver"
314 \consists "Hyphen_engraver"
315 \consists "Stanza_number_engraver"
316 \consists "Skip_event_swallow_translator"
317 phrasingPunctuation = #".,:!?\""
318 SeparationItem \set #'padding = #0.5
320 NoteNamesContext = \translator {
321 \type "Engraver_group_engraver"
323 \consistsend "Axis_group_engraver"
325 minimumVerticalExtent = ##f
326 extraVerticalExtent = ##f
330 \consists "Note_name_engraver"
331 \consists "Separating_line_group_engraver"
334 LyricsContext = \translator {
335 \type "Engraver_group_engraver"
337 \description "Typesets lyrics."
338 %% To get folded repeats right.
339 \consists Vertical_align_engraver
341 \consistsend "Hara_kiri_engraver"
342 minimumVerticalExtent = ##f
343 extraVerticalExtent = ##f
346 \accepts "LyricsVoice"
350 ChordNamesContext = \translator {
351 \type "Engraver_group_engraver"
353 \description " Typesets chord names."
355 \consists "Rest_swallow_translator"
356 \consists "Output_property_engraver"
357 \consists "Separating_line_group_engraver"
358 \consists "Chord_name_engraver"
359 \consists "Skip_event_swallow_translator"
360 \consistsend "Hara_kiri_engraver"
361 minimumVerticalExtent = #'(0 . 2.5)
362 extraVerticalExtent = ##f
367 RemoveEmptyStaffContext = \translator {
369 \remove "Axis_group_engraver"
370 \consistsend "Hara_kiri_engraver"
371 \consists "Instrument_name_engraver"
374 % hara kiri & auto knee don't work together.
375 Beam \override #'auto-knee-gap = #'()
378 HaraKiriStaffContext = \translator {
379 \RemoveEmptyStaffContext
380 \accepts "VaticanaVoice"
383 ScoreContext = \translator {
386 localKeySignature = #'()
388 \description "This is the top level notation context. No
389 other context can contain a @code{Score} context. This context
390 handles the administration of time signatures. It also makes sure
391 that items such as clefs, time signatures, and key-signatures are
392 aligned across staves.
394 You cannot explicitly instantiate a Score context (since it is
395 not contained in any other context). It is instantiated
396 automatically when an output definition (a @code{\score} or
397 @code{\paper} block) is processed."
399 \consists "Repeat_acknowledge_engraver"
400 \consists "Staff_collecting_engraver"
402 % move the alias along with the engraver.
404 %% TODO? add this alias from Timing_engraver::initialize() ?
405 \consists "Timing_engraver"
408 \consists "Output_property_engraver"
409 \consists "System_start_delimiter_engraver"
410 \consists "Mark_engraver"
411 \consists "Metronome_mark_engraver"
412 \consists "Break_align_engraver"
413 \consists "Spacing_engraver"
414 \consists "Vertical_align_engraver"
415 \consists "Lyric_phrasing_engraver"
416 \consists "Bar_number_engraver"
417 \consists "Span_arpeggio_engraver"
421 \accepts "VaticanaStaff"
422 \accepts "StaffContainer"
423 \accepts "StaffGroup"
424 \accepts "RhythmicStaff"
426 \accepts "ChordNames"
427 \accepts "GrandStaff"
428 \accepts "ChoirStaff"
429 \accepts "PianoStaff"
431 \accepts "FiguredBass"
434 soloIIText = #"Solo II"
437 splitInterval = #'(0 . 1)
438 changeMoment = #`(,(ly:make-moment 0 0) . ,(ly:make-moment 1 512))
439 systemStartDelimiter =#'SystemStartBar
442 clefGlyph = #"clefs-G"
444 centralCPosition = #-6
446 automaticPhrasing = ##t
447 automaticMelismata = ##t
449 defaultBarType = #"|"
450 barNumberVisibility = #default-bar-number-visibility
453 explicitClefVisibility = #all-visible
454 explicitKeySignatureVisibility = #all-visible
455 autoBeamSettings = #default-auto-beam-settings
457 scriptDefinitions = #default-script-alist
459 verticalAlignmentChildCallback = #Align_interface::alignment_callback
461 pedalSustainStrings = #'("Ped." "*Ped." "*")
462 pedalSustainStyle = #'text
463 pedalUnaCordaStrings = #'("una corda" "" "tre corde")
464 pedalUnaCordaStyle = #'text
466 %% These are in ordinary italic font, including the *,
467 %% but they are unlikely to be used,
468 %% as the default pedal-style for SostenutoPedal is 'mixed':
469 %% i.e. Sost. Ped_____________________
470 pedalSostenutoStrings = #'("Sost. Ped." "*Sost. Ped." "*")
471 pedalSostenutoStyle = #'mixed
474 tupletNumberFormatFunction = #denominator-tuplet-formatter
479 autoAccidentals = #'(Staff (same-octave . 0))
480 autoCautionaries = #'()
482 keyAccidentalOrder = #'(
483 (6 . -1) (2 . -1) (5 . -1 ) (1 . -1) (4 . -1) (0 . -1) (3 . -1)
484 (3 . 1) (0 . 1) (4 . 1) (1 . 1) (5 . 1) (2 . 1) (6 . 1)
485 (6 . -2) (2 . -2) (5 . -2 ) (1 . -2) (4 . -2) (0 . -2) (3 . -2)
486 (3 . 2) (0 . 2) (4 . 2) (2 . 2) (5 . 2) (2 . 2) (6 . 2)
488 breakAlignOrder = #'(
499 barCheckSynchronize = ##t
502 chordNameFunction = #ignatzek-chord-names
503 majorSevenSymbol = #whiteTriangleMarkup
504 chordNameSeparator = #(make-simple-markup "/")
505 chordNameExceptions = #ignatzekExceptions
506 chordNoteNamer = #'()
507 chordRootNamer = #note-name->markup
509 chordNameExceptionsFull = #fullJazzExceptions
510 chordNameExceptionsPartial = #partialJazzExceptions
513 stringOneTopmost = ##t
516 %% One may change the strings tuning as following :
517 %% The lenght of the list must be equal to the number of string
518 stringTunings = #guitar-tunings
519 tablatureFormat = #fret-number-tablature-format
522 bassFigureFormatFunction = #make-bass-figure-markup
523 metronomeMarkFormatter = #make-metronome-markup
525 \grobdescriptions #all-grob-descriptions
528 OrchestralScoreContext= \translator {
532 EasyNotation = \translator {
534 NoteHead \override #'molecule-callback = #Note_head::brew_ez_molecule
539 FiguredBassContext = \translator {
540 \type "Engraver_group_engraver"
542 \consists "Figured_bass_engraver"
543 \consists "Rest_swallow_translator"
544 \consists "Note_swallow_translator"
545 \consists "Separating_line_group_engraver"
547 \consistsend "Hara_kiri_engraver"
550 TabVoiceContext = \translator {
554 \consists "Tab_note_heads_engraver"
555 \remove "Fingering_engraver"
556 \remove "New_fingering_engraver"
558 Slur \override #'font-family = #'roman
559 Slur \override #'molecule-callback = #hammer-molecule-callback
560 Slur \override #'direction = #-1
562 % Draws all stems/beams out of the staff (and not in the middle of the staff !)
563 % This feature is now disabled because most of the tab does not use it.
564 %Beam \override #'damping = #100000
565 %Stem \override #'up-to-staff = ##t
567 % No accidental in tablature !
568 \remove Accidental_engraver
571 TabStaffContext = \translator {
577 \description "Context for generating tablature. [DOCME]"
582 StaffSymbol \override #'line-count = #6
583 StaffSymbol \override #'staff-space = #1.5
585 % Don't draw stems over the tablature figures !
586 Stem \override #'avoid-note-head = ##t
588 % No accidental in tablature !
589 \remove Accidental_engraver
593 clefGlyph = #"clefs-tab"
597 % TODO: Gregorian Chant contexts should be moved to gregorian-init.ly,
598 % but this does not work (is this a bug or intended behaviour?):
600 % If I try to do so, I get "error: unknown escaped string:
601 % `\VaticanaStaffContext'" in params-init.ly. If I also move
602 % "\translator { \Vaticana*Context }" from params-init.ly to the end
603 % of gregorian-init.ly, then I get "error: parse error, unexpected
604 % TRANSLATOR: \translator { \VaticanaStaffContext }" in
605 % gregorian-init.ly. --jr
607 VaticanaVoiceContext = \translator {
609 \name "VaticanaVoice"
611 \description "Same as @code{Voice} context, except that it is accommodated for tyepsetting Gregorian Chant in the notational style of Editio Vaticana."
613 % We can not remove Slur_engraver, since \addlyrics depends on it.
614 % Instead, we make the grob transparent.
615 % Unfortunately, this gives us a lot of warnings ("Degenerate bow:
616 % infinite steepness reqd"), since in ligatures, all note heads are in
617 % the same paper column such that the (transparent) slurs eventually may
618 % start and end in the same column.
619 Slur \override #'transparent = ##t
621 % We can not remove Stem_engraver, since slurs depend on stems. If
622 % we try anyway, lily will crash in slur.scm:16:6: "Wrong type argument
623 % in position 1 (expecting grob): ()".
624 % As a workaround, we make the grob transparent.
625 Stem \set #'transparent = ##t
627 \remove "Ligature_bracket_engraver"
628 \consists "Vaticana_ligature_engraver"
630 % Set default head for notes outside of \[ \].
631 NoteHead \set #'style = #'vaticana_punctum
633 % Put some space before and after divisiones.
634 % FIXME: This does not seem to show any effect.
635 Script \set #'padding = #0.5
637 % There are no beams in Gregorian Chant notation.
640 % Prepare TextSpanner for \episem{Initium|Finis} use.
641 TextSpanner \set #'style = #'line
642 TextSpanner \set #'edge-height = #'(0 . 0)
643 TextSpanner \set #'padding = #0.5
644 TextSpanner \set #'edge-text = #'("" . "")
647 VaticanaStaffContext = \translator {
649 \name "VaticanaStaff"
652 \accepts "VaticanaVoice"
653 % \description "Same as @code{Staff} context, except that it is accommodated for tyepsetting Gregorian Chant in the notational style of Editio Vaticana."
655 \remove "Time_signature_engraver"
656 \consists "Custos_engraver"
658 % We can not remove Bar_engraver, since clef and custos depend on it.
659 % Instead, we make the grob transparent.
660 BarLine \set #'transparent = ##t
662 StaffSymbol \set #'line-count = #4
664 % FIXME: unit on StaffSymbol's width should be \linewidth.
665 % StaffSymbol \set #'width = #60.0
667 % Choose vaticana do clef on 3rd line as default.
668 clefGlyph = #"clefs-vaticana_do"
669 centralCPosition = #1
673 % Select vaticana style font.
674 KeySignature \set #'style = #'vaticana
675 Accidental \set #'style = #'vaticana
676 Custos \set #'style = #'vaticana
677 Custos \set #'neutral-position = #3
678 Custos \set #'neutral-direction = #-1
679 Custos \set #'adjust-if-on-staffline = ##t
682 % Score.barAlways = ##t