1 ;;;; define-grobs.scm --
3 ;;;; source file of the GNU LilyPond music typesetter
5 ;;;; (c) 1998--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
6 ;;;; Jan Nieuwenhuizen <janneke@gnu.org>
8 ;;;; distances are given in linethickness (thicknesses) and
9 ;;;; staffspace (distances)
11 ;;;; WARNING: the meta field should be the last one.
12 ;;;; WARNING: don't use anonymous functions for initialization.
14 ;; TODO: junk the meta field in favor of something more compact?
15 (define-public all-grob-descriptions
19 (print-function . ,Accidental_interface::print)
21 (cautionary-style . parentheses)
22 (after-line-breaking-callback . ,Accidental_interface::after_line_breaking) (meta . ((interfaces . (item-interface accidental-interface font-interface))))
27 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
30 ;; this is quite small, but it is very ugly to have
31 ;; accs closer to the previous note than to the next one.
32 (right-padding . 0.15)
33 (meta . ((interfaces . (item-interface accidental-placement-interface))))
39 (break-align-symbol . ambitus)
40 (print-function . ,Ambitus::print)
42 (note-head-style . "noteheads-2")
43 (break-visibility . ,begin-of-line-visible)
46 (clef . (extra-space . 0.0))
47 (key-signature . (extra-space . 0.0))
48 (staff-bar . (extra-space . 0.0))
49 (time-signature . (extra-space . 0.0))
50 (first-note . (fixed-space . 0.0))
52 (meta . ((interfaces . (ambitus-interface staff-symbol-referencer-interface break-aligned-interface item-interface font-interface))))
57 (X-extent-callback . ,Arpeggio::width_callback)
58 (Y-extent-callback . #f)
59 (print-function . ,Arpeggio::print)
60 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
61 (X-offset-callbacks . (,Side_position_interface::aligned_side))
64 (staff-position . 0.0)
65 (meta . ((interfaces . (arpeggio-interface staff-symbol-referencer-interface side-position-interface item-interface font-interface))))
70 (break-align-symbol . staff-bar)
72 (break-glyph-function . ,default-break-barline)
73 (bar-size-procedure . ,Bar_line::get_staff_bar_size)
74 (print-function . ,Bar_line::print)
75 (break-visibility . ,all-visible)
77 (before-line-breaking-callback . ,Bar_line::before_line_breaking)
79 (time-signature . (extra-space . 0.75))
80 (custos . (minimum-space . 2.0))
81 (clef . (minimum-space . 1.0))
82 (key-signature . (extra-space . 1.0))
83 (first-note . (fixed-space . 1.3))
84 (next-note . (semi-fixed-space . 1.3))
85 (right-edge . (extra-space . 0.0))
89 ;; Ross. page 151 lists other values, we opt for a leaner look
93 (hair-thickness . 1.6)
94 (thick-thickness . 6.0)
95 (meta . ((interfaces . (bar-line-interface item-interface break-aligned-interface font-interface))))
101 (print-function . ,Text_item::print)
103 (break-visibility . ,begin-of-line-visible)
106 (font-family . roman)
108 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
109 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
110 (self-alignment-X . 1)
112 ;; hmm. why did we do this: ?
113 (extra-offset . (1.3 . 0))
115 ((interfaces . (side-position-interface
117 self-alignment-interface
118 font-interface item-interface break-aligned-interface))))
124 (print-function . ,Text_item::print)
125 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
127 (font-family . number)
129 ;; We must do this, other BFs in
130 ;; paper16 become too small.
133 (meta . ((interfaces . (text-interface rhythmic-grob-interface
134 bass-figure-interface item-interface
135 self-alignment-interface font-interface))))
139 ;; todo: clean this up a bit: the list is getting
141 (print-function . ,Beam::print)
142 (concaveness-gap . 1.85)
143 (concaveness-threshold . 0.26)
145 (positions . (#f . #f))
146 (position-callbacks . (,Beam::least_squares
149 ,Beam::shift_region_to_valid
153 ;; TODO: should be in SLT.
154 (thickness . 0.48) ; in staff-space
155 (before-line-breaking-callback . ,Beam::before_line_breaking)
156 (after-line-breaking-callback . ,Beam::after_line_breaking)
157 (neutral-direction . -1)
158 (dir-function . ,beam-dir-majority-median)
160 ;; Whe have some unreferenced problems here.
162 ;; If we shorten beamed stems less than normal stems (1 staffspace),
163 ;; or high order less than 8th beams, patterns like
164 ;; c''4 [c''8 c''] c''4 [c''16 c]
165 ;; are ugly (different stem lengths).
167 ;; But if we shorten 16th beams as much as 8th beams, a single
168 ;; forced 16th beam looks *very* short.
170 ;; We choose to shorten 8th beams the same as single stems,
171 ;; and high order beams less than 8th beams, so that all
172 ;; isolated shortened beams look nice and a bit shortened,
173 ;; sadly possibly breaking patterns with high order beams.
174 (beamed-stem-shorten . (1.0 0.5 0.25))
177 (flag-width-function . ,beam-flag-width-function)
179 (auto-knee-gap . 5.5)
181 ;; only for debugging.
182 (font-family . roman)
184 (space-function . ,Beam::space_function)
185 (meta . ((interfaces . (staff-symbol-referencer-interface beam-interface spanner-interface))))
192 (break-align-orders . #(; end-of-line:
193 (instrument-name left-edge ambitus breathing-sign
194 clef staff-bar key-signature
195 time-signature custos)
198 (instrument-name left-edge ambitus breathing-sign
199 clef staff-bar key-signature
201 time-signature custos)
203 (instrument-name left-edge ambitus breathing-sign
204 clef key-signature staff-bar
205 time-signature custos)
209 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
210 (meta . ((interfaces . (break-alignment-interface item-interface axis-group-interface)))))
216 (X-offset-callbacks . (,Break_align_interface::alignment_callback))
217 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
218 (meta . ((interfaces . (break-aligned-interface item-interface axis-group-interface item-interface ))))
223 (break-align-symbol . breathing-sign)
226 (ambitus . (extra-space . 2.0))
227 (custos . (minimum-space . 1.0))
228 (key-signature . (minimum-space . 1.5))
229 (staff-bar . (minimum-space . 1.5))
230 (clef . (minimum-space . 2.0))
231 (first-note . (fixed-space . 1.0)) ;huh?
232 (right-edge . (extra-space . 0.1))
234 (print-function . ,Text_item::print)
235 (text . ,(make-musicglyph-markup "scripts-rcomma"))
236 (Y-offset-callbacks . (,Breathing_sign::offset_callback))
237 (break-visibility . ,begin-of-line-invisible)
238 (meta . ((interfaces . (break-aligned-interface breathing-sign-interface text-interface font-interface item-interface ))))
243 (print-function . ,Clef::print)
244 (before-line-breaking-callback . ,Clef::before_line_breaking)
246 (font-family . music)
247 (break-align-symbol . clef)
248 (break-visibility . ,begin-of-line-visible)
249 (space-alist . ((ambitus . (extra-space . 2.0))
250 (staff-bar . (extra-space . 0.7))
251 (key-signature . (minimum-space . 4.0))
252 (time-signature . (minimum-space . 4.2))
253 (first-note . (minimum-fixed-space . 5.0))
254 (next-note . (extra-space . 0.5))
255 (right-edge . (extra-space . 0.5))
257 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
258 (meta . ((interfaces . (clef-interface staff-symbol-referencer-interface font-interface break-aligned-interface item-interface ))))
261 (ClusterSpannerBeacon
263 (print-function . #f)
264 (Y-extent-callback . ,Cluster_beacon::height)
265 (meta . ((interfaces . (cluster-beacon-interface item-interface))))
270 (print-function . ,Cluster::print)
271 (spacing-procedure . ,Spanner::set_spacing_rods)
272 (minimum-length . 0.0)
275 (meta . ((interfaces . (cluster-interface spanner-interface))))
280 (print-function . ,Text_item::print)
281 (after-line-breaking-callback . ,Chord_name::after_line_breaking)
285 (meta . ((interfaces . (font-interface rhythmic-grob-interface
286 text-interface chord-name-interface item-interface ))))
291 (break-align-symbol . custos)
293 (print-function . ,Custos::print)
294 (break-visibility . ,end-of-line-visible)
296 (neutral-direction . -1)
297 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
299 (first-note . (minimum-fixed-space . 0.0))
300 (right-edge . (extra-space . 0.1))
303 . (custos-interface staff-symbol-referencer-interface
305 break-aligned-interface item-interface ))))
313 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
314 (X-offset-callbacks . (,Dot_column::side_position))
315 (meta . ((interfaces . (dot-column-interface axis-group-interface item-interface ))))
320 (print-function . ,Dots::print)
322 (meta . ((interfaces . (font-interface staff-symbol-referencer-interface dots-interface item-interface ))))
325 (DoublePercentRepeat .
327 (print-function . ,Percent_repeat_item_interface::double_percent)
330 (font-encoding . fetaMusic)
333 (break-align-symbol . staff-bar)
334 (break-visibility . ,begin-of-line-invisible)
335 (meta . ((interfaces . (font-interface
336 break-aligned-interface
337 percent-repeat-interface item-interface ))))
342 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
343 (print-function . ,Text_item::print)
344 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
345 ,Self_alignment_interface::centered_on_parent))
346 (self-alignment-X . 0)
347 (no-spacing-rods . #t)
348 (script-priority . 100)
350 (font-encoding . fetaDynamic)
351 (font-shape . italic)
352 (self-alignment-Y . 0)
353 (meta . ((interfaces . (font-interface text-interface self-alignment-interface dynamic-interface script-interface item-interface))))
359 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
360 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
361 (staff-padding . 0.1)
363 (minimum-space . 1.2)
365 (meta . ((interfaces . (dynamic-interface axis-group-interface side-position-interface spanner-interface))))
370 (break-align-symbol . left-edge)
374 (custos . (extra-space . 0.0))
375 (ambitus . (extra-space . 2.0))
376 (time-signature . (extra-space . 0.0))
377 (staff-bar . (extra-space . 0.0))
378 (breathing-sign . (minimum-space . 0.0))
379 (clef . (extra-space . 0.85))
380 (first-note . (fixed-space . 1.0))
381 (right-edge . (extra-space . 0.0))
382 (key-signature . (extra-space . 0.0))
384 (meta . ((interfaces . (break-aligned-interface item-interface ))))
389 (print-function . ,Text_item::print)
391 (staff-padding . 0.6)
392 (self-alignment-X . 0)
393 (self-alignment-Y . 0)
394 (script-priority . 100)
395 (font-encoding . fetaNumber)
396 (font-size . -5) ; don't overlap when next to heads.
397 (meta . ((interfaces . (finger-interface font-interface text-script-interface text-interface side-position-interface self-alignment-interface item-interface ))))
404 (zigzag-width . 0.75)
406 (X-extent-callback . #f)
407 (Y-extent-callback . #f)
408 (after-line-breaking-callback . ,Line_spanner::after_line_breaking)
409 (print-function . ,Line_spanner::print)
410 (meta . ((interfaces . (line-spanner-interface spanner-interface))))
415 (print-function . ,Hairpin::print)
418 (spacing-procedure . ,Spanner::set_spacing_rods)
419 (minimum-length . 2.0)
420 (if-text-padding . 1.0)
421 (self-alignment-Y . 0)
422 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
423 (meta . ((interfaces . (hairpin-interface line-interface self-alignment-interface dynamic-interface spanner-interface))))
429 (print-function . ,Horizontal_bracket::print)
430 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
433 (meta . ((interfaces . (horizontal-bracket-interface side-position-interface spanner-interface))))
438 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self
439 ,Side_position_interface::aligned_on_support_refpoints))
440 ;; This direction is for aligned_on_support_refpoints
444 (left-edge . (extra-space . 1.0))
447 (self-alignment-Y . 0)
448 (print-function . ,Text_item::print)
449 (break-align-symbol . instrument-name)
450 (break-visibility . ,begin-of-line-visible)
452 (meta . ((interfaces . (font-interface self-alignment-interface side-position-interface text-interface break-aligned-interface item-interface ))))
458 (Y-offset-callbacks . (,Side_position_interface::aligned_on_support_refpoints))
460 (space-alist . ((left-edge . (extra-space . 1.0))
462 (break-align-symbol . instrument-name)
463 (print-function . ,Text_item::print)
464 (break-align-symbol . clef)
465 (break-visibility . ,begin-of-line-visible)
467 (meta . ((interfaces . (font-interface
468 self-alignment-interface
469 side-position-interface text-interface
470 break-aligned-interface item-interface ))))
475 (print-function . ,Key_signature_interface::print)
477 (time-signature . (extra-space . 1.25))
478 (staff-bar . (extra-space . 1.1))
479 (right-edge . (extra-space . 0.5))
480 (first-note . (fixed-space . 2.5))
482 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
483 (break-align-symbol . key-signature)
484 (break-visibility . ,begin-of-line-visible)
486 (meta . ((interfaces . (key-signature-interface font-interface break-aligned-interface item-interface ))))
491 (ligature-primitive-callback . ,Note_head::print)
496 (edge-height . (0.7 . 0.7))
497 (shorten-pair . (-0.2 . -0.2))
498 (before-line-breaking-callback . ,Tuplet_bracket::before_line_breaking)
499 (after-line-breaking-callback . ,Tuplet_bracket::after_line_breaking)
500 (print-function . ,Tuplet_bracket::print)
501 (meta . ((interfaces . (tuplet-bracket-interface spanner-interface))))
510 (spacing-procedure . ,Hyphen_spanner::set_spacing_rods)
511 (print-function . ,Hyphen_spanner::print)
513 (meta . ((interfaces . (lyric-interface lyric-hyphen-interface
514 spanner-interface))))
519 (print-function . ,Lyric_extender::print)
520 (thickness . 0.8) ; linethickness
521 (minimum-length . 1.5)
523 (meta . ((interfaces . (lyric-interface
524 lyric-extender-interface spanner-interface))))
528 . ((print-function . ,Text_item::print)
529 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_parent))
530 (self-alignment-X . 0)
532 (font-series . bold-narrow)
534 (meta . ((interfaces . (rhythmic-grob-interface lyric-syllable-interface self-alignment-interface text-interface font-interface item-interface ))))
541 (ligature-primitive-callback . ,Mensural_ligature::brew_ligature_primitive)
542 (print-function . ,Mensural_ligature::print)
543 (meta . ((interfaces . (mensural-ligature-interface font-interface))))
548 (print-function . ,Text_item::print)
549 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
550 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
551 (after-line-breaking-callback . ,shift-right-at-line-begin)
552 (self-alignment-X . 0)
557 (break-visibility . ,end-of-line-invisible)
559 (meta . ((interfaces . (text-interface side-position-interface font-interface mark-interface self-alignment-interface item-interface ))))
563 (print-function . ,Text_item::print)
564 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
567 (break-visibility . ,end-of-line-invisible)
569 (meta . ((interfaces . (text-interface side-position-interface font-interface metronome-mark-interface item-interface))))
573 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
574 (print-function . ,Measure_grouping::print)
580 (meta . ((interfaces . (spanner-interface side-position-interface measure-grouping-interface))))
584 (spacing-procedure . ,Multi_measure_rest::set_spacing_rods)
585 (print-function . ,Multi_measure_rest::print)
586 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
589 (thick-thickness . 6.6)
590 (hair-thickness . 2.0)
592 (font-encoding . fetaMusic)
593 (meta . ((interfaces . (multi-measure-rest-interface multi-measure-interface rest-interface font-interface staff-symbol-referencer-interface))))
596 (MultiMeasureRestNumber
598 (print-function . ,Text_item::print)
599 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
600 ,Self_alignment_interface::centered_on_other_axis_parent))
601 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
602 (self-alignment-X . 0)
605 (staff-padding . 1.3)
606 (font-encoding . fetaNumber)
607 (meta . ((interfaces . (side-position-interface multi-measure-interface self-alignment-interface font-interface spanner-interface text-interface))))
609 (MultiMeasureRestText
611 (print-function . ,Text_item::print)
612 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
613 ,Self_alignment_interface::centered_on_other_axis_parent))
614 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
615 (self-alignment-X . 0)
618 (staff-padding . 1.5)
619 (meta . ((interfaces . (side-position-interface multi-measure-interface self-alignment-interface font-interface spanner-interface text-interface))))
624 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
625 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
626 (meta . ((interfaces . (note-collision-interface axis-group-interface item-interface ))))
632 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
633 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
634 (meta . ((interfaces . (axis-group-interface note-column-interface item-interface ))))
640 (print-function . ,Note_head::print)
641 (ligature-primitive-callback . ,Note_head::print)
642 (glyph-name-procedure . ,find-notehead-symbol)
643 (X-extent-callback . ,Note_head::extent)
644 (Y-extent-callback . ,Note_head::extent)
645 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
646 (stem-attachment-function . ,note-head-style->attachment-coordinates)
647 (meta . ((interfaces . (rhythmic-grob-interface rhythmic-head-interface font-interface note-head-interface staff-symbol-referencer-interface item-interface ))))
652 (stem-spacing-correction . 0.5)
654 ;; Changed this from 0.75.
655 ;; If you ever change this back, please document! --hwn
656 (knee-spacing-correction . 1.0)
658 (meta . ((interfaces . (spacing-interface note-spacing-interface item-interface ))))
666 (X-extent-callback . #f)
667 (Y-extent-callback . #f)
668 (print-function . ,Line_spanner::print)
669 (after-line-breaking-callback . ,Line_spanner::after_line_breaking)
670 (meta . ((interfaces . (line-spanner-interface spanner-interface))))
675 (print-function . ,Text_item::print)
676 (meta . ((interfaces . (note-name-interface
677 text-interface font-interface item-interface ))))
682 (self-alignment-X . 0)
683 (break-visibility . ,begin-of-line-visible)
684 (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent ,Self_alignment_interface::aligned_on_self))
685 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
686 (print-function . ,Text_item::print)
688 ;; no Y dimensions, because of lyrics under tenor clef.
689 (Y-extent-callback . #f)
690 (font-shape . italic)
692 (staff-padding . 0.2)
694 (meta . ((interfaces . (text-interface self-alignment-interface side-position-interface font-interface item-interface ))))
700 (before-line-breaking-callback . ,Paper_column::before_line_breaking)
701 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
703 ;ppp (print-function . ,Paper_column::print) (font-name . "cmr8") (Y-extent-callback . #f)
704 (meta . ((interfaces . (paper-column-interface axis-group-interface spaceable-grob-interface item-interface ))))
709 (print-function . ,Slur::print)
711 (spacing-procedure . ,Spanner::set_spacing_rods)
712 (minimum-length . 1.5)
713 (after-line-breaking-callback . ,Slur::after_line_breaking)
714 (extremity-function . ,calc-slur-extremity)
715 (extremity-offset-alist . ,default-phrasing-slur-extremity-offset-alist)
716 (de-uglify-parameters . (1.5 0.8 -2.0))
717 (Y-extent-callback . ,Slur::height)
722 (attachment . (#f . #f))
723 (attachment-offset . ((0 . 0) . (0 . 0)))
725 (details . ((force-blowfit . 0.5)
726 (bezier-pct-c0 . -0.2) (bezier-pct-c3 . 0.000006)
727 (bezier-pct-out-max . 0.8) (bezier-pct-in-max . 1.2)
728 (bezier-area-steps . 1.0)))
729 (meta . ((interfaces . (slur-interface spanner-interface))))
732 (NonMusicalPaperColumn
735 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
736 (before-line-breaking-callback . ,Paper_column::before_line_breaking)
738 ;; debugging stuff: print column number.
739 ; (print-function . ,Paper_column::print) (font-name . "cmr8") (Y-extent-callback . #f)
742 (meta . ((interfaces . (paper-column-interface axis-group-interface spaceable-grob-interface item-interface ))))
747 (spacing-procedure . ,Multi_measure_rest::set_spacing_rods)
748 (print-function . ,Multi_measure_rest::percent)
751 (font-encoding . fetaMusic)
752 (meta . ((interfaces . (multi-measure-rest-interface spanner-interface font-interface percent-repeat-interface))))
755 (PianoPedalBracket ;; an example of a text spanner
757 (print-function . ,Piano_pedal_bracket::print)
759 (if-text-padding . 1.0)
761 (bracket-flare . (0.5 . 0.5))
762 (edge-height . (1.0 . 1.0))
763 (shorten-pair . (0.0 . 0.0))
765 (meta . ((interfaces . (line-interface piano-pedal-interface piano-pedal-bracket-interface spanner-interface))))
769 (RemoveEmptyVerticalGroup
771 (Y-offset-callbacks . (,Hara_kiri_group_spanner::force_hara_kiri_callback))
772 (Y-extent-callback . ,Hara_kiri_group_spanner::y_extent)
775 (meta . ((interfaces . (axis-group-interface hara-kiri-group-interface item-interface spanner-interface))))
780 (print-function . ,Percent_repeat_item_interface::beat_slash)
783 (meta . ((interfaces . (percent-repeat-interface item-interface ))))
787 (after-line-breaking-callback . ,Rest::after_line_breaking)
788 (X-extent-callback . ,Rest::extent_callback)
789 (Y-extent-callback . ,Rest::extent_callback)
790 (print-function . ,Rest::print)
791 (Y-offset-callbacks . (,Staff_symbol_referencer::callback
792 ,Rest::polyphonic_offset_callback
794 (minimum-distance . 0.25)
796 (interfaces . (font-interface
797 rhythmic-head-interface
798 rhythmic-grob-interface
799 staff-symbol-referencer-interface
800 rest-interface item-interface ))
805 (minimum-distance . 0.75)
806 (meta . ((interfaces . (rest-collision-interface item-interface ))))
811 ;; don't set direction here: it breaks staccato.
812 (print-function . ,Script_interface::print)
814 ;; This value is sensitive: if too large, staccato dots will move a
817 (staff-padding . 0.25)
818 ;; (script-priority . 0) priorities for scripts, see script.scm
819 (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent))
820 (before-line-breaking-callback . ,Script_interface::before_line_breaking)
821 (font-encoding . fetaMusic)
822 (meta . ((interfaces . (script-interface side-position-interface font-interface item-interface ))))
827 (before-line-breaking-callback . ,Script_column::before_line_breaking)
828 (meta . ((interfaces . (script-column-interface item-interface ))))
833 (print-function . ,Slur::print)
835 (spacing-procedure . ,Spanner::set_spacing_rods)
836 (minimum-length . 1.5)
837 (after-line-breaking-callback . ,Slur::after_line_breaking)
838 (extremity-function . ,calc-slur-extremity)
839 (extremity-offset-alist . ,default-slur-extremity-offset-alist)
840 (de-uglify-parameters . (1.5 0.8 -2.0))
841 (Y-extent-callback . ,Slur::height)
846 (attachment . (#f . #f))
847 (attachment-offset . ((0 . 0) . (0 . 0)))
849 (details . ((force-blowfit . 0.5)
850 (bezier-pct-c0 . -0.2) (bezier-pct-c3 . 0.000006)
851 (bezier-pct-out-max . 0.8) (bezier-pct-in-max . 1.2)
852 (bezier-area-steps . 1.0)))
853 (meta . ((interfaces . (slur-interface spanner-interface))))
858 (spacing-procedure . ,Spacing_spanner::set_springs)
859 (grace-space-factor . 0.6)
860 (shortest-duration-space . 2.0)
861 (spacing-increment . 1.2)
862 (base-shortest-duration . ,(ly:make-moment 1 8))
863 (meta . ((interfaces . (spacing-interface spacing-spanner-interface spanner-interface))))
868 (break-align-symbol . staff-bar)
869 (bar-size-procedure . ,Span_bar::get_bar_size)
870 (print-function . ,Span_bar::print)
871 (break-visibility . ,begin-of-line-invisible)
872 (X-extent-callback . ,Span_bar::width_callback)
873 (Y-extent-callback . ())
875 (before-line-breaking-callback . ,Span_bar::before_line_breaking)
879 ;; Ross. page 151 lists other values, we opt for a leaner look
883 (hair-thickness . 1.6)
884 (thick-thickness . 6.0)
885 (meta . ((interfaces . (span-bar-interface font-interface
886 bar-line-interface item-interface ))))
890 . ((print-function . ,Text_item::print)
893 (X-offset-callbacks . (,Side_position_interface::aligned_side))
895 (meta . ((interfaces . (side-position-interface stanza-number-interface text-interface font-interface item-interface ))))
901 (stem-spacing-correction . 0.4)
903 (meta . ((interfaces . (spacing-interface staff-spacing-interface item-interface ))))
908 (print-function . ,Text_item::print)
910 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
911 (no-spacing-rods . #t)
912 (padding . 0.0) ;; padding relative to SostenutoPedalLineSpanner
913 (font-shape . italic)
914 (self-alignment-X . 0)
915 (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface))))
918 (SostenutoPedalLineSpanner
921 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
922 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
926 (minimum-space . 1.0)
928 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
933 (print-function . ,Staff_symbol::print)
935 (ledger-line-thickness . (1.0 . 0.1))
937 (meta . ((interfaces . (staff-symbol-interface spanner-interface))))
942 ;; this list is rather long. Trim --hwn
943 (before-line-breaking-callback . ,Stem::before_line_breaking)
944 (print-function . ,Stem::print)
947 ;; 3.5 (or 3 measured from note head) is standard length
948 ;; 32nd, 64th flagged stems should be longer
949 (lengths . (3.5 3.5 3.5 4.5 5.0))
951 ;; Stems in unnatural (forced) direction should be shortened by
952 ;; one staff space, according to [Roush & Gourlay].
953 ;; Flagged stems we shorten only half a staff space.
954 (stem-shorten . (1.0 0.5))
956 ;; default stem direction for note on middle line
957 (neutral-direction . -1)
961 ;; FIXME. 3.5 yields too long beams (according to Ross and
962 ;; looking at Baerenreiter examples) for a number of common
963 ;; boundary cases. Subtracting half a beam thickness fixes
964 ;; this, but the bug may well be somewhere else.
966 ;; FIXME this should come from 'lengths
968 ; (beamed-lengths . (3.26 3.26 1.5))
969 (beamed-lengths . (3.5 3.5 3.5 4.5 5.0))
971 ;; We use the normal minima as minimum for the ideal lengths,
972 ;; and the extreme minima as abolute minimum length.
974 ;; The 'normal' minima
975 (beamed-minimum-free-lengths . (1.83 1.5 1.25))
977 ;; The 'extreme case' minima
978 (beamed-extreme-minimum-free-lengths . (2.0 1.25))
980 (X-offset-callbacks . (,Stem::off_callback))
981 (X-extent-callback . ,Stem::dim_callback)
982 (Y-extent-callback . ,Stem::height)
983 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
984 (meta . ((interfaces . (stem-interface font-interface item-interface ))))
989 (print-function . ,Stem_tremolo::print)
990 (Y-extent-callback . ,Stem_tremolo::height)
991 (X-extent-callback . #f)
993 (beam-width . 1.6) ; staff-space
994 (beam-thickness . 0.48) ; staff-space
995 (meta . ((interfaces . (stem-tremolo-interface item-interface ))))
1000 (X-extent-callback . #f)
1001 (Y-extent-callback . #f)
1002 (meta . ((interfaces . (spacing-interface separation-item-interface item-interface ))))
1005 (SeparatingGroupSpanner
1007 (spacing-procedure . ,Separating_group_spanner::set_spacing_rods)
1008 (meta . ((interfaces . (only-prebreak-interface spacing-interface separation-spanner-interface spanner-interface))))
1013 (no-spacing-rods . #t)
1014 (print-function . ,Sustain_pedal::print)
1015 (self-alignment-X . 0)
1017 (padding . 0.0) ;; padding relative to SustainPedalLineSpanner
1018 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1019 (meta . ((interfaces . (piano-pedal-interface text-spanner-interface text-interface self-alignment-interface font-interface item-interface))))
1022 (SustainPedalLineSpanner
1025 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1026 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1029 (staff-padding . 1.2)
1030 (minimum-space . 1.0)
1032 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1038 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1039 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1040 (meta . ((interfaces . (system-interface axis-group-interface spanner-interface))))
1046 (print-function . ,System_start_delimiter::print)
1047 (collapse-height . 5.0)
1048 (font-encoding . fetaBraces)
1049 (Y-extent-callback . #f)
1050 (meta . ((interfaces . (system-start-delimiter-interface font-interface))))
1055 (Y-extent-callback . #f)
1056 (print-function . ,System_start_delimiter::print)
1062 (collapse-height . 1)
1064 (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
1069 (Y-extent-callback . #f)
1070 (print-function . ,System_start_delimiter::print)
1071 (glyph . "bar-line")
1073 (after-line-breaking-callback . ,System_start_delimiter::after_line_breaking)
1074 (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
1079 (print-function . ,Text_item::print)
1080 (no-spacing-rods . #t)
1081 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1084 (staff-padding . 0.5)
1085 (script-priority . 200)
1086 ;; todo: add X self alignment?
1087 (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1091 (print-function . ,Text_item::print)
1092 (no-spacing-rods . #t)
1093 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1094 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1096 (extra-offset . (-1 . 0))
1098 (staff-padding . 0.5)
1099 (script-priority . 200)
1100 ;; todo: add X self alignment?
1102 (font-series . bold)
1103 (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1107 (print-function . ,Text_spanner::print)
1108 (font-shape . italic)
1109 (style . dashed-line)
1110 (staff-padding . 0.1)
1112 ;; urg, only for (de)cresc. text spanners
1113 (if-text-padding . 1.0)
1114 (dash-fraction . 0.2)
1117 (meta . ((interfaces . (text-spanner-interface side-position-interface font-interface spanner-interface))))
1122 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1123 (print-function . ,Ottava_bracket::print)
1124 (font-shape . italic)
1125 (shorten-pair . (0.0 . -0.6))
1126 (staff-padding . 1.0)
1128 (minimum-length . 1.0)
1129 (dash-fraction . 0.3)
1130 (edge-height . (0 . 1.2))
1132 (meta . ((interfaces . (ottava-bracket-interface
1133 line-interface side-position-interface
1134 font-interface text-interface spanner-interface))))
1140 (print-function . ,Text_item::print)
1141 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
1142 (extra-offset . (0 . -0.65)) ;; UGH! TODO: Clean this up!
1143 (stem-attachment-function . ,tablature-stem-attachment-function)
1144 (meta . ((interfaces
1145 . (rhythmic-head-interface
1147 note-head-interface staff-symbol-referencer-interface
1148 text-interface item-interface ))))
1154 (print-function . ,Tie::print)
1155 (spacing-procedure . ,Spanner::set_spacing_rods)
1156 (staffline-clearance . 0.35)
1157 (details . ((ratio . 0.333) (height-limit . 1.0)))
1161 (minimum-length . 2.5)
1162 (meta . ((interfaces . (tie-interface spanner-interface))))
1167 (after-line-breaking-callback . ,Tie_column::after_line_breaking)
1168 (X-extent-callback . #f)
1169 (Y-extent-callback . #f)
1170 (meta . ((interfaces . (tie-column-interface spanner-interface))))
1175 (print-function . ,Time_signature::print)
1176 ; (print-function . ,Text_item::print)
1177 (break-align-symbol . time-signature)
1178 (break-visibility . ,all-visible)
1180 (first-note . (fixed-space . 2.0))
1181 (right-edge . (extra-space . 0.5))
1182 (staff-bar . (minimum-space . 2.0))
1186 ; (text . (,time-signature-glue-markup))
1187 (meta . ((interfaces . (time-signature-interface break-aligned-interface font-interface item-interface ))))
1194 (edge-height . (0.7 . 0.7))
1195 (shorten-pair . (-0.2 . -0.2))
1196 (before-line-breaking-callback . ,Tuplet_bracket::before_line_breaking)
1197 (after-line-breaking-callback . ,Tuplet_bracket::after_line_breaking)
1198 (print-function . ,Tuplet_bracket::print)
1199 (font-shape . italic)
1200 (font-series . bold)
1203 (meta . ((interfaces . (text-interface line-interface tuplet-bracket-interface font-interface spanner-interface))))
1208 (print-function . ,Text_item::print)
1209 (font-shape . italic)
1210 (no-spacing-rods . #t)
1211 (self-alignment-X . 0)
1213 (padding . 0.0) ;; padding relative to UnaCordaPedalLineSpanner
1214 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1215 (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface ))))
1218 (UnaCordaPedalLineSpanner
1221 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1222 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1224 (staff-padding . 1.2)
1225 (minimum-space . 1.0)
1227 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1234 (ligature-primitive-callback . ,Vaticana_ligature::brew_ligature_primitive)
1235 (print-function . ,Vaticana_ligature::print)
1236 (meta . ((interfaces . (vaticana-ligature-interface font-interface))))
1241 (print-function . ,Volta_bracket_interface::print)
1244 (font-encoding . fetaNumber)
1245 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1246 (thickness . 1.6) ; linethickness
1247 (height . 2.0) ; staffspace;
1250 (meta . ((interfaces . (volta-bracket-interface line-interface text-interface side-position-interface font-interface spanner-interface))))
1256 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1257 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1259 (meta . ((interfaces . (align-interface axis-group-interface spanner-interface))))
1265 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1266 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1268 (meta . ((interfaces . (axis-group-interface spanner-interface))))
1276 (define (completize-grob-entry x)
1277 "transplant assoc key into 'name entry of 'meta of X
1279 (let* ((name-sym (car x))
1280 (grob-entry (cdr x))
1281 (metaentry (cdr (assoc 'meta grob-entry)))
1283 (cdr (assoc 'interfaces metaentry)))
1286 (set! metaentry (assoc-set! metaentry 'name name-sym))
1287 (set! metaentry (assoc-set! metaentry 'interfaces
1288 (cons 'grob-interface ifaces-entry)))
1289 (set! grob-entry (assoc-set! grob-entry 'meta metaentry))
1290 (cons name-sym grob-entry)))
1292 (set! all-grob-descriptions (map completize-grob-entry all-grob-descriptions))
1296 ; (display (map pair? all-grob-descriptions))
1299 ;; make sure that \property Foo.Bar =\turnOff doesn't complain
1302 ; (display (car x)) (newline)
1304 (set-object-property! (car x) 'translation-type? list?)
1305 (set-object-property! (car x) 'is-grob? #t))
1306 all-grob-descriptions)
1309 (set! all-grob-descriptions (sort all-grob-descriptions alist<?))