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 (X-extent-callback . ,Span_bar::width_callback)
872 (Y-extent-callback . ())
874 (before-line-breaking-callback . ,Span_bar::before_line_breaking)
878 ;; Ross. page 151 lists other values, we opt for a leaner look
882 (hair-thickness . 1.6)
883 (thick-thickness . 6.0)
884 (meta . ((interfaces . (span-bar-interface font-interface
885 bar-line-interface item-interface ))))
889 . ((print-function . ,Text_item::print)
892 (X-offset-callbacks . (,Side_position_interface::aligned_side))
894 (meta . ((interfaces . (side-position-interface stanza-number-interface text-interface font-interface item-interface ))))
900 (stem-spacing-correction . 0.4)
902 (meta . ((interfaces . (spacing-interface staff-spacing-interface item-interface ))))
907 (print-function . ,Text_item::print)
909 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
910 (no-spacing-rods . #t)
911 (padding . 0.0) ;; padding relative to SostenutoPedalLineSpanner
912 (font-shape . italic)
913 (self-alignment-X . 0)
914 (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface))))
917 (SostenutoPedalLineSpanner
920 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
921 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
925 (minimum-space . 1.0)
927 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
932 (print-function . ,Staff_symbol::print)
934 (ledger-line-thickness . (1.0 . 0.1))
936 (meta . ((interfaces . (staff-symbol-interface spanner-interface))))
941 ;; this list is rather long. Trim --hwn
942 (before-line-breaking-callback . ,Stem::before_line_breaking)
943 (print-function . ,Stem::print)
946 ;; 3.5 (or 3 measured from note head) is standard length
947 ;; 32nd, 64th flagged stems should be longer
948 (lengths . (3.5 3.5 3.5 4.5 5.0))
950 ;; Stems in unnatural (forced) direction should be shortened by
951 ;; one staff space, according to [Roush & Gourlay].
952 ;; Flagged stems we shorten only half a staff space.
953 (stem-shorten . (1.0 0.5))
955 ;; default stem direction for note on middle line
956 (neutral-direction . -1)
960 ;; FIXME. 3.5 yields too long beams (according to Ross and
961 ;; looking at Baerenreiter examples) for a number of common
962 ;; boundary cases. Subtracting half a beam thickness fixes
963 ;; this, but the bug may well be somewhere else.
965 ;; FIXME this should come from 'lengths
967 ; (beamed-lengths . (3.26 3.26 1.5))
968 (beamed-lengths . (3.5 3.5 3.5 4.5 5.0))
970 ;; We use the normal minima as minimum for the ideal lengths,
971 ;; and the extreme minima as abolute minimum length.
973 ;; The 'normal' minima
974 (beamed-minimum-free-lengths . (1.83 1.5 1.25))
976 ;; The 'extreme case' minima
977 (beamed-extreme-minimum-free-lengths . (2.0 1.25))
979 (X-offset-callbacks . (,Stem::off_callback))
980 (X-extent-callback . ,Stem::dim_callback)
981 (Y-extent-callback . ,Stem::height)
982 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
983 (meta . ((interfaces . (stem-interface font-interface item-interface ))))
988 (print-function . ,Stem_tremolo::print)
989 (Y-extent-callback . ,Stem_tremolo::height)
990 (X-extent-callback . #f)
992 (beam-width . 1.6) ; staff-space
993 (beam-thickness . 0.48) ; staff-space
994 (meta . ((interfaces . (stem-tremolo-interface item-interface ))))
999 (X-extent-callback . #f)
1000 (Y-extent-callback . #f)
1001 (meta . ((interfaces . (spacing-interface separation-item-interface item-interface ))))
1004 (SeparatingGroupSpanner
1006 (spacing-procedure . ,Separating_group_spanner::set_spacing_rods)
1007 (meta . ((interfaces . (only-prebreak-interface spacing-interface separation-spanner-interface spanner-interface))))
1012 (no-spacing-rods . #t)
1013 (print-function . ,Sustain_pedal::print)
1014 (self-alignment-X . 0)
1016 (padding . 0.0) ;; padding relative to SustainPedalLineSpanner
1017 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1018 (meta . ((interfaces . (piano-pedal-interface text-spanner-interface text-interface self-alignment-interface font-interface item-interface))))
1021 (SustainPedalLineSpanner
1024 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1025 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1028 (staff-padding . 1.2)
1029 (minimum-space . 1.0)
1031 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1037 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1038 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1039 (meta . ((interfaces . (system-interface axis-group-interface spanner-interface))))
1045 (print-function . ,System_start_delimiter::print)
1046 (collapse-height . 5.0)
1047 (font-encoding . fetaBraces)
1048 (Y-extent-callback . #f)
1049 (meta . ((interfaces . (system-start-delimiter-interface font-interface))))
1054 (Y-extent-callback . #f)
1055 (print-function . ,System_start_delimiter::print)
1061 (collapse-height . 1)
1063 (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
1068 (Y-extent-callback . #f)
1069 (print-function . ,System_start_delimiter::print)
1070 (glyph . "bar-line")
1072 (after-line-breaking-callback . ,System_start_delimiter::after_line_breaking)
1073 (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
1078 (print-function . ,Text_item::print)
1079 (no-spacing-rods . #t)
1080 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1083 (staff-padding . 0.5)
1084 (script-priority . 200)
1085 ;; todo: add X self alignment?
1086 (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1090 (print-function . ,Text_item::print)
1091 (no-spacing-rods . #t)
1092 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1093 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1095 (extra-offset . (-1 . 0))
1097 (staff-padding . 0.5)
1098 (script-priority . 200)
1099 ;; todo: add X self alignment?
1101 (font-series . bold)
1102 (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1106 (print-function . ,Text_spanner::print)
1107 (font-shape . italic)
1108 (style . dashed-line)
1109 (staff-padding . 0.1)
1111 ;; urg, only for (de)cresc. text spanners
1112 (if-text-padding . 1.0)
1113 (dash-fraction . 0.2)
1116 (meta . ((interfaces . (text-spanner-interface side-position-interface font-interface spanner-interface))))
1121 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1122 (print-function . ,Ottava_bracket::print)
1123 (font-shape . italic)
1124 (shorten-pair . (0.0 . -0.6))
1125 (staff-padding . 1.0)
1127 (minimum-length . 1.0)
1128 (dash-fraction . 0.3)
1129 (edge-height . (0 . 1.2))
1131 (meta . ((interfaces . (ottava-bracket-interface
1132 line-interface side-position-interface
1133 font-interface text-interface spanner-interface))))
1139 (print-function . ,Text_item::print)
1140 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
1141 (extra-offset . (0 . -0.65)) ;; UGH! TODO: Clean this up!
1142 (stem-attachment-function . ,tablature-stem-attachment-function)
1143 (meta . ((interfaces
1144 . (rhythmic-head-interface
1146 note-head-interface staff-symbol-referencer-interface
1147 text-interface item-interface ))))
1153 (print-function . ,Tie::print)
1154 (spacing-procedure . ,Spanner::set_spacing_rods)
1155 (staffline-clearance . 0.35)
1156 (details . ((ratio . 0.333) (height-limit . 1.0)))
1160 (minimum-length . 2.5)
1161 (meta . ((interfaces . (tie-interface spanner-interface))))
1166 (after-line-breaking-callback . ,Tie_column::after_line_breaking)
1167 (X-extent-callback . #f)
1168 (Y-extent-callback . #f)
1169 (meta . ((interfaces . (tie-column-interface spanner-interface))))
1174 (print-function . ,Time_signature::print)
1175 ; (print-function . ,Text_item::print)
1176 (break-align-symbol . time-signature)
1177 (break-visibility . ,all-visible)
1179 (first-note . (fixed-space . 2.0))
1180 (right-edge . (extra-space . 0.5))
1181 (staff-bar . (minimum-space . 2.0))
1185 ; (text . (,time-signature-glue-markup))
1186 (meta . ((interfaces . (time-signature-interface break-aligned-interface font-interface item-interface ))))
1193 (edge-height . (0.7 . 0.7))
1194 (shorten-pair . (-0.2 . -0.2))
1195 (before-line-breaking-callback . ,Tuplet_bracket::before_line_breaking)
1196 (after-line-breaking-callback . ,Tuplet_bracket::after_line_breaking)
1197 (print-function . ,Tuplet_bracket::print)
1198 (font-shape . italic)
1199 (font-series . bold)
1202 (meta . ((interfaces . (text-interface line-interface tuplet-bracket-interface font-interface spanner-interface))))
1207 (print-function . ,Text_item::print)
1208 (font-shape . italic)
1209 (no-spacing-rods . #t)
1210 (self-alignment-X . 0)
1212 (padding . 0.0) ;; padding relative to UnaCordaPedalLineSpanner
1213 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1214 (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface ))))
1217 (UnaCordaPedalLineSpanner
1220 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1221 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1223 (staff-padding . 1.2)
1224 (minimum-space . 1.0)
1226 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1233 (ligature-primitive-callback . ,Vaticana_ligature::brew_ligature_primitive)
1234 (print-function . ,Vaticana_ligature::print)
1235 (meta . ((interfaces . (vaticana-ligature-interface font-interface))))
1240 (print-function . ,Volta_bracket_interface::print)
1243 (font-encoding . fetaNumber)
1244 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1245 (thickness . 1.6) ; linethickness
1246 (height . 2.0) ; staffspace;
1249 (meta . ((interfaces . (volta-bracket-interface line-interface text-interface side-position-interface font-interface spanner-interface))))
1255 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1256 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1258 (meta . ((interfaces . (align-interface axis-group-interface spanner-interface))))
1264 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1265 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1267 (meta . ((interfaces . (axis-group-interface spanner-interface))))
1275 (define (completize-grob-entry x)
1276 "transplant assoc key into 'name entry of 'meta of X
1278 (let* ((name-sym (car x))
1279 (grob-entry (cdr x))
1280 (metaentry (cdr (assoc 'meta grob-entry)))
1282 (cdr (assoc 'interfaces metaentry)))
1285 (set! metaentry (assoc-set! metaentry 'name name-sym))
1286 (set! metaentry (assoc-set! metaentry 'interfaces
1287 (cons 'grob-interface ifaces-entry)))
1288 (set! grob-entry (assoc-set! grob-entry 'meta metaentry))
1289 (cons name-sym grob-entry)))
1291 (set! all-grob-descriptions (map completize-grob-entry all-grob-descriptions))
1295 ; (display (map pair? all-grob-descriptions))
1298 ;; make sure that \property Foo.Bar =\turnOff doesn't complain
1301 ; (display (car x)) (newline)
1303 (set-object-property! (car x) 'translation-type? list?)
1304 (set-object-property! (car x) 'is-grob? #t))
1305 all-grob-descriptions)
1308 (set! all-grob-descriptions (sort all-grob-descriptions alist<?))