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)
196 (instrument-name left-edge ambitus breathing-sign
197 clef staff-bar key-signature
199 time-signature custos)
200 (instrument-name left-edge ambitus breathing-sign
201 clef key-signature staff-bar
202 time-signature custos)
206 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
207 (meta . ((interfaces . (break-alignment-interface item-interface axis-group-interface)))))
213 (X-offset-callbacks . (,Break_align_interface::alignment_callback))
214 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
215 (meta . ((interfaces . (break-aligned-interface item-interface axis-group-interface item-interface ))))
220 (break-align-symbol . breathing-sign)
223 (ambitus . (extra-space . 2.0))
224 (custos . (minimum-space . 1.0))
225 (key-signature . (minimum-space . 1.5))
226 (staff-bar . (minimum-space . 1.5))
227 (clef . (minimum-space . 2.0))
228 (first-note . (fixed-space . 1.0)) ;huh?
229 (right-edge . (extra-space . 0.1))
231 (print-function . ,Text_item::print)
232 (text . ,(make-musicglyph-markup "scripts-rcomma"))
233 (Y-offset-callbacks . (,Breathing_sign::offset_callback))
234 (break-visibility . ,begin-of-line-invisible)
235 (meta . ((interfaces . (break-aligned-interface breathing-sign-interface text-interface font-interface item-interface ))))
240 (print-function . ,Clef::print)
241 (before-line-breaking-callback . ,Clef::before_line_breaking)
243 (font-family . music)
244 (break-align-symbol . clef)
245 (break-visibility . ,begin-of-line-visible)
246 (space-alist . ((ambitus . (extra-space . 2.0))
247 (staff-bar . (extra-space . 0.7))
248 (key-signature . (minimum-space . 4.0))
249 (time-signature . (minimum-space . 4.2))
250 (first-note . (minimum-fixed-space . 5.0))
251 (next-note . (extra-space . 0.5))
252 (right-edge . (extra-space . 0.5))
254 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
255 (meta . ((interfaces . (clef-interface staff-symbol-referencer-interface font-interface break-aligned-interface item-interface ))))
258 (ClusterSpannerBeacon
260 (print-function . #f)
261 (meta . ((interfaces . (cluster-beacon-interface item-interface))))
266 (print-function . ,Cluster::print)
267 (spacing-procedure . ,Spanner::set_spacing_rods)
268 (minimum-length . 0.0)
271 (meta . ((interfaces . (cluster-interface spanner-interface))))
276 (print-function . ,Text_item::print)
277 (after-line-breaking-callback . ,Chord_name::after_line_breaking)
281 (meta . ((interfaces . (font-interface rhythmic-grob-interface
282 text-interface chord-name-interface item-interface ))))
287 (break-align-symbol . custos)
289 (print-function . ,Custos::print)
290 (break-visibility . ,end-of-line-visible)
292 (neutral-direction . -1)
293 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
295 (first-note . (minimum-fixed-space . 0.0))
296 (right-edge . (extra-space . 0.1))
299 . (custos-interface staff-symbol-referencer-interface
301 break-aligned-interface item-interface ))))
309 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
310 (X-offset-callbacks . (,Dot_column::side_position))
311 (meta . ((interfaces . (dot-column-interface axis-group-interface item-interface ))))
316 (print-function . ,Dots::print)
318 (meta . ((interfaces . (font-interface staff-symbol-referencer-interface dots-interface item-interface ))))
321 (DoublePercentRepeat .
323 (print-function . ,Percent_repeat_item_interface::double_percent)
326 (font-encoding . music)
329 (break-align-symbol . staff-bar)
330 (break-visibility . ,begin-of-line-invisible)
331 (meta . ((interfaces . (font-interface
332 break-aligned-interface
333 percent-repeat-interface item-interface ))))
338 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
339 (print-function . ,Text_item::print)
340 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
341 ,Self_alignment_interface::centered_on_parent))
342 (self-alignment-X . 0)
343 (no-spacing-rods . #t)
344 (script-priority . 100)
346 (font-encoding . dynamic)
347 (font-shape . italic)
348 (self-alignment-Y . 0)
349 (meta . ((interfaces . (font-interface text-interface self-alignment-interface dynamic-interface script-interface item-interface))))
355 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
356 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
357 (staff-padding . 0.1)
359 (minimum-space . 1.2)
361 (meta . ((interfaces . (dynamic-interface axis-group-interface side-position-interface spanner-interface))))
366 (break-align-symbol . left-edge)
370 (custos . (extra-space . 0.0))
371 (ambitus . (extra-space . 2.0))
372 (time-signature . (extra-space . 0.0))
373 (staff-bar . (extra-space . 0.0))
374 (breathing-sign . (minimum-space . 0.0))
375 (clef . (extra-space . 0.85))
376 (first-note . (fixed-space . 1.0))
377 (right-edge . (extra-space . 0.0))
378 (key-signature . (extra-space . 0.0))
380 (meta . ((interfaces . (break-aligned-interface item-interface ))))
385 (print-function . ,Text_item::print)
387 (staff-padding . 0.6)
388 (self-alignment-X . 0)
389 (self-alignment-Y . 0)
390 (script-priority . 100)
391 (font-encoding . number)
392 (font-size . -5) ; don't overlap when next to heads.
393 (font-shape . upright)
394 (meta . ((interfaces . (finger-interface font-interface text-script-interface text-interface side-position-interface self-alignment-interface item-interface ))))
401 (zigzag-width . 0.75)
403 (X-extent-callback . #f)
404 (Y-extent-callback . #f)
405 (after-line-breaking-callback . ,Line_spanner::after_line_breaking)
406 (print-function . ,Line_spanner::print)
407 (meta . ((interfaces . (line-spanner-interface spanner-interface))))
412 (print-function . ,Hairpin::print)
415 (spacing-procedure . ,Spanner::set_spacing_rods)
416 (minimum-length . 2.0)
417 (if-text-padding . 1.0)
418 (self-alignment-Y . 0)
419 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
420 (meta . ((interfaces . (hairpin-interface line-interface self-alignment-interface dynamic-interface spanner-interface))))
426 (print-function . ,Horizontal_bracket::print)
427 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
430 (meta . ((interfaces . (horizontal-bracket-interface side-position-interface spanner-interface))))
435 (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self
436 ,Side_position_interface::aligned_on_support_refpoints))
437 ;; This direction is for aligned_on_support_refpoints
441 (left-edge . (extra-space . 1.0))
444 (self-alignment-Y . 0)
445 (print-function . ,Text_item::print)
446 (break-align-symbol . instrument-name)
447 (break-visibility . ,begin-of-line-visible)
449 (meta . ((interfaces . (font-interface self-alignment-interface side-position-interface text-interface break-aligned-interface item-interface ))))
455 (Y-offset-callbacks . (,Side_position_interface::aligned_on_support_refpoints))
457 (space-alist . ((left-edge . (extra-space . 1.0))
459 (print-function . ,Text_item::print)
460 (break-align-symbol . clef)
461 (break-visibility . ,begin-of-line-visible)
463 (meta . ((interfaces . (font-interface
464 self-alignment-interface
465 side-position-interface text-interface
466 break-aligned-interface item-interface ))))
471 (print-function . ,Key_signature_interface::print)
473 (time-signature . (extra-space . 1.25))
474 (staff-bar . (extra-space . 1.1))
475 (right-edge . (extra-space . 0.5))
476 (first-note . (fixed-space . 2.5))
478 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
479 (break-align-symbol . key-signature)
480 (break-visibility . ,begin-of-line-visible)
482 (meta . ((interfaces . (key-signature-interface font-interface break-aligned-interface item-interface ))))
487 (ligature-primitive-callback . ,Note_head::print)
492 (edge-height . (0.7 . 0.7))
493 (shorten-pair . (-0.2 . -0.2))
494 (before-line-breaking-callback . ,Tuplet_bracket::before_line_breaking)
495 (after-line-breaking-callback . ,Tuplet_bracket::after_line_breaking)
496 (print-function . ,Tuplet_bracket::print)
497 (meta . ((interfaces . (tuplet-bracket-interface spanner-interface))))
506 (spacing-procedure . ,Hyphen_spanner::set_spacing_rods)
507 (print-function . ,Hyphen_spanner::print)
509 (meta . ((interfaces . (lyric-interface lyric-hyphen-interface
510 spanner-interface))))
515 (print-function . ,Lyric_extender::print)
516 (thickness . 0.8) ; linethickness
517 (minimum-length . 1.5)
519 (meta . ((interfaces . (lyric-interface
520 lyric-extender-interface spanner-interface))))
524 . ((print-function . ,Text_item::print)
525 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_parent))
526 (self-alignment-X . 0)
528 (font-series . bold-narrow)
530 (meta . ((interfaces . (rhythmic-grob-interface lyric-syllable-interface self-alignment-interface text-interface font-interface item-interface ))))
537 (ligature-primitive-callback . ,Mensural_ligature::brew_ligature_primitive)
538 (print-function . ,Mensural_ligature::print)
539 (meta . ((interfaces . (mensural-ligature-interface font-interface))))
544 (print-function . ,Text_item::print)
545 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
546 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
547 (after-line-breaking-callback . ,shift-right-at-line-begin)
548 (self-alignment-X . 0)
553 (break-visibility . ,end-of-line-invisible)
555 (meta . ((interfaces . (text-interface side-position-interface font-interface mark-interface self-alignment-interface item-interface ))))
559 (print-function . ,Text_item::print)
560 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
563 (break-visibility . ,end-of-line-invisible)
565 (meta . ((interfaces . (text-interface side-position-interface font-interface metronome-mark-interface item-interface))))
569 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
570 (print-function . ,Measure_grouping::print)
576 (meta . ((interfaces . (spanner-interface side-position-interface measure-grouping-interface))))
580 (spacing-procedure . ,Multi_measure_rest::set_spacing_rods)
581 (print-function . ,Multi_measure_rest::print)
582 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
585 (thick-thickness . 6.6)
586 (hair-thickness . 2.0)
588 (font-encoding . music)
589 (meta . ((interfaces . (multi-measure-rest-interface multi-measure-interface rest-interface font-interface staff-symbol-referencer-interface))))
592 (MultiMeasureRestNumber
594 (print-function . ,Text_item::print)
595 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
596 ,Self_alignment_interface::centered_on_other_axis_parent))
597 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
598 (self-alignment-X . 0)
601 (staff-padding . 1.3)
602 (font-encoding . number)
603 (meta . ((interfaces . (side-position-interface multi-measure-interface self-alignment-interface font-interface spanner-interface text-interface))))
605 (MultiMeasureRestText
607 (print-function . ,Text_item::print)
608 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
609 ,Self_alignment_interface::centered_on_other_axis_parent))
610 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
611 (self-alignment-X . 0)
614 (staff-padding . 1.5)
615 (meta . ((interfaces . (side-position-interface multi-measure-interface self-alignment-interface font-interface spanner-interface text-interface))))
620 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
621 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
622 (meta . ((interfaces . (note-collision-interface axis-group-interface item-interface ))))
628 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
629 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
630 (meta . ((interfaces . (axis-group-interface note-column-interface item-interface ))))
636 (print-function . ,Note_head::print)
637 (ligature-primitive-callback . ,Note_head::print)
638 (glyph-name-procedure . ,find-notehead-symbol)
639 (X-extent-callback . ,Note_head::extent)
640 (Y-extent-callback . ,Note_head::extent)
641 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
642 (stem-attachment-function . ,note-head-style->attachment-coordinates)
643 (meta . ((interfaces . (rhythmic-grob-interface rhythmic-head-interface font-interface note-head-interface staff-symbol-referencer-interface item-interface ))))
648 (stem-spacing-correction . 0.5)
650 ;; Changed this from 0.75.
651 ;; If you ever change this back, please document! --hwn
652 (knee-spacing-correction . 1.0)
654 (meta . ((interfaces . (spacing-interface note-spacing-interface item-interface ))))
662 (X-extent-callback . #f)
663 (Y-extent-callback . #f)
664 (print-function . ,Line_spanner::print)
665 (after-line-breaking-callback . ,Line_spanner::after_line_breaking)
666 (meta . ((interfaces . (line-spanner-interface spanner-interface))))
671 (print-function . ,Text_item::print)
672 (meta . ((interfaces . (note-name-interface
673 text-interface font-interface item-interface ))))
678 (self-alignment-X . 0)
679 (break-visibility . ,begin-of-line-visible)
680 (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent ,Self_alignment_interface::aligned_on_self))
681 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
682 (print-function . ,Text_item::print)
683 (font-shape . italic)
685 (staff-padding . 0.2)
687 (meta . ((interfaces . (text-interface self-alignment-interface side-position-interface font-interface item-interface ))))
693 (before-line-breaking-callback . ,Paper_column::before_line_breaking)
694 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
696 ; (print-function . ,Paper_column::print) (font-name . "cmr8") (Y-extent-callback . #f)
697 (meta . ((interfaces . (paper-column-interface axis-group-interface spaceable-grob-interface item-interface ))))
702 (print-function . ,Slur::print)
704 (spacing-procedure . ,Spanner::set_spacing_rods)
705 (minimum-length . 1.5)
706 (after-line-breaking-callback . ,Slur::after_line_breaking)
707 (extremity-function . ,calc-slur-extremity)
708 (extremity-offset-alist . ,default-phrasing-slur-extremity-offset-alist)
709 (de-uglify-parameters . (1.5 0.8 -2.0))
710 (Y-extent-callback . ,Slur::height)
715 (attachment . (#f . #f))
716 (attachment-offset . ((0 . 0) . (0 . 0)))
718 (details . ((force-blowfit . 0.5)
719 (bezier-pct-c0 . -0.2) (bezier-pct-c3 . 0.000006)
720 (bezier-pct-out-max . 0.8) (bezier-pct-in-max . 1.2)
721 (bezier-area-steps . 1.0)))
722 (meta . ((interfaces . (slur-interface spanner-interface))))
725 (NonMusicalPaperColumn
728 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
729 (before-line-breaking-callback . ,Paper_column::before_line_breaking)
731 ;; debugging stuff: print column number.
732 ; (print-function . ,Paper_column::print) (font-name . "cmr8") (Y-extent-callback . #f)
735 (meta . ((interfaces . (paper-column-interface axis-group-interface spaceable-grob-interface item-interface ))))
740 (spacing-procedure . ,Multi_measure_rest::set_spacing_rods)
741 (print-function . ,Multi_measure_rest::percent)
744 (font-encoding . music)
745 (meta . ((interfaces . (multi-measure-rest-interface spanner-interface font-interface percent-repeat-interface))))
748 (PianoPedalBracket ;; an example of a text spanner
750 (print-function . ,Piano_pedal_bracket::print)
752 (if-text-padding . 1.0)
754 (bracket-flare . (0.5 . 0.5))
755 (edge-height . (1.0 . 1.0))
756 (shorten-pair . (0.0 . 0.0))
758 (meta . ((interfaces . (line-interface piano-pedal-interface piano-pedal-bracket-interface spanner-interface))))
762 (RemoveEmptyVerticalGroup
764 (Y-offset-callbacks . (,Hara_kiri_group_spanner::force_hara_kiri_callback))
765 (Y-extent-callback . ,Hara_kiri_group_spanner::y_extent)
768 (meta . ((interfaces . (axis-group-interface hara-kiri-group-interface item-interface spanner-interface))))
773 (print-function . ,Percent_repeat_item_interface::beat_slash)
776 (meta . ((interfaces . (percent-repeat-interface item-interface ))))
780 (after-line-breaking-callback . ,Rest::after_line_breaking)
781 (X-extent-callback . ,Rest::extent_callback)
782 (Y-extent-callback . ,Rest::extent_callback)
783 (print-function . ,Rest::print)
784 (Y-offset-callbacks . (,Staff_symbol_referencer::callback
785 ,Rest::polyphonic_offset_callback
787 (minimum-distance . 0.25)
789 (interfaces . (font-interface
790 rhythmic-head-interface
791 rhythmic-grob-interface
792 staff-symbol-referencer-interface
793 rest-interface item-interface ))
798 (minimum-distance . 0.75)
799 (meta . ((interfaces . (rest-collision-interface item-interface ))))
804 ;; don't set direction here: it breaks staccato.
805 (print-function . ,Script_interface::print)
807 ;; This value is sensitive: if too large, staccato dots will move a
810 (staff-padding . 0.25)
811 ;; (script-priority . 0) priorities for scripts, see script.scm
812 (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent))
813 (before-line-breaking-callback . ,Script_interface::before_line_breaking)
814 (font-encoding . music)
815 (meta . ((interfaces . (script-interface side-position-interface font-interface item-interface ))))
820 (before-line-breaking-callback . ,Script_column::before_line_breaking)
821 (meta . ((interfaces . (script-column-interface item-interface ))))
826 (print-function . ,Slur::print)
828 (spacing-procedure . ,Spanner::set_spacing_rods)
829 (minimum-length . 1.5)
830 (after-line-breaking-callback . ,Slur::after_line_breaking)
831 (extremity-function . ,calc-slur-extremity)
832 (extremity-offset-alist . ,default-slur-extremity-offset-alist)
833 (de-uglify-parameters . (1.5 0.8 -2.0))
834 (Y-extent-callback . ,Slur::height)
839 (attachment . (#f . #f))
840 (attachment-offset . ((0 . 0) . (0 . 0)))
842 (details . ((force-blowfit . 0.5)
843 (bezier-pct-c0 . -0.2) (bezier-pct-c3 . 0.000006)
844 (bezier-pct-out-max . 0.8) (bezier-pct-in-max . 1.2)
845 (bezier-area-steps . 1.0)))
846 (meta . ((interfaces . (slur-interface spanner-interface))))
851 (spacing-procedure . ,Spacing_spanner::set_springs)
852 (grace-space-factor . 0.6)
853 (shortest-duration-space . 2.0)
854 (spacing-increment . 1.2)
855 (base-shortest-duration . ,(ly:make-moment 1 8))
856 (meta . ((interfaces . (spacing-interface spacing-spanner-interface spanner-interface))))
861 (break-align-symbol . staff-bar)
862 (bar-size-procedure . ,Span_bar::get_bar_size)
863 (print-function . ,Span_bar::print)
864 (break-visibility . ,begin-of-line-invisible)
865 (X-extent-callback . ,Span_bar::width_callback)
866 (Y-extent-callback . ())
868 (before-line-breaking-callback . ,Span_bar::before_line_breaking)
872 ;; Ross. page 151 lists other values, we opt for a leaner look
876 (hair-thickness . 1.6)
877 (thick-thickness . 6.0)
878 (meta . ((interfaces . (span-bar-interface font-interface
879 bar-line-interface item-interface ))))
883 . ((print-function . ,Text_item::print)
886 (X-offset-callbacks . (,Side_position_interface::aligned_side))
888 (meta . ((interfaces . (side-position-interface stanza-number-interface text-interface font-interface item-interface ))))
894 (stem-spacing-correction . 0.4)
896 (meta . ((interfaces . (spacing-interface staff-spacing-interface item-interface ))))
901 (print-function . ,Text_item::print)
903 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
904 (no-spacing-rods . #t)
905 (padding . 0.0) ;; padding relative to SostenutoPedalLineSpanner
906 (font-shape . italic)
907 (self-alignment-X . 0)
908 (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface))))
911 (SostenutoPedalLineSpanner
914 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
915 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
919 (minimum-space . 1.0)
921 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
926 (print-function . ,Staff_symbol::print)
928 (ledger-line-thickness . (1.0 . 0.1))
930 (meta . ((interfaces . (staff-symbol-interface spanner-interface))))
935 ;; this list is rather long. Trim --hwn
936 (before-line-breaking-callback . ,Stem::before_line_breaking)
937 (print-function . ,Stem::print)
940 ;; 3.5 (or 3 measured from note head) is standard length
941 ;; 32nd, 64th flagged stems should be longer
942 (lengths . (3.5 3.5 3.5 4.5 5.0))
944 ;; Stems in unnatural (forced) direction should be shortened by
945 ;; one staff space, according to [Roush & Gourlay].
946 ;; Flagged stems we shorten only half a staff space.
947 (stem-shorten . (1.0 0.5))
949 ;; default stem direction for note on middle line
950 (neutral-direction . -1)
954 ;; FIXME. 3.5 yields too long beams (according to Ross and
955 ;; looking at Baerenreiter examples) for a number of common
956 ;; boundary cases. Subtracting half a beam thickness fixes
957 ;; this, but the bug may well be somewhere else.
959 ;; FIXME this should come from 'lengths
961 ; (beamed-lengths . (3.26 3.26 1.5))
962 (beamed-lengths . (3.5 3.5 3.5 4.5 5.0))
964 ;; We use the normal minima as minimum for the ideal lengths,
965 ;; and the extreme minima as abolute minimum length.
967 ;; The 'normal' minima
968 (beamed-minimum-free-lengths . (1.83 1.5 1.25))
970 ;; The 'extreme case' minima
971 (beamed-extreme-minimum-free-lengths . (2.0 1.25))
973 (X-offset-callbacks . (,Stem::off_callback))
974 (X-extent-callback . ,Stem::dim_callback)
975 (Y-extent-callback . ,Stem::height)
976 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
977 (meta . ((interfaces . (stem-interface font-interface item-interface ))))
982 (print-function . ,Stem_tremolo::print)
983 (Y-extent-callback . ,Stem_tremolo::height)
984 (X-extent-callback . #f)
986 (beam-width . 1.6) ; staff-space
987 (beam-thickness . 0.48) ; staff-space
988 (meta . ((interfaces . (stem-tremolo-interface item-interface ))))
993 (X-extent-callback . #f)
994 (Y-extent-callback . #f)
995 (meta . ((interfaces . (spacing-interface separation-item-interface item-interface ))))
998 (SeparatingGroupSpanner
1000 (spacing-procedure . ,Separating_group_spanner::set_spacing_rods)
1001 (meta . ((interfaces . (only-prebreak-interface spacing-interface separation-spanner-interface spanner-interface))))
1006 (no-spacing-rods . #t)
1007 (print-function . ,Sustain_pedal::print)
1008 (self-alignment-X . 0)
1010 (padding . 0.0) ;; padding relative to SustainPedalLineSpanner
1011 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1012 (meta . ((interfaces . (piano-pedal-interface text-spanner-interface text-interface self-alignment-interface font-interface item-interface))))
1015 (SustainPedalLineSpanner
1018 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1019 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1022 (staff-padding . 1.2)
1023 (minimum-space . 1.0)
1025 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1031 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1032 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1033 (meta . ((interfaces . (system-interface axis-group-interface spanner-interface))))
1039 (print-function . ,System_start_delimiter::print)
1040 (collapse-height . 5.0)
1041 (font-encoding . braces)
1042 (Y-extent-callback . #f)
1043 (meta . ((interfaces . (system-start-delimiter-interface font-interface))))
1048 (Y-extent-callback . #f)
1049 (print-function . ,System_start_delimiter::print)
1055 (collapse-height . 1)
1057 (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
1062 (Y-extent-callback . #f)
1063 (print-function . ,System_start_delimiter::print)
1064 (glyph . "bar-line")
1066 (after-line-breaking-callback . ,System_start_delimiter::after_line_breaking)
1067 (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
1072 (print-function . ,Text_item::print)
1073 (no-spacing-rods . #t)
1074 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1077 (staff-padding . 0.5)
1078 (script-priority . 200)
1079 ;; todo: add X self alignment?
1080 (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1084 (print-function . ,Text_item::print)
1085 (no-spacing-rods . #t)
1086 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1087 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1089 (extra-offset . (-1 . 0))
1091 (staff-padding . 0.5)
1092 (script-priority . 200)
1093 ;; todo: add X self alignment?
1095 (font-series . bold)
1096 (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1100 (print-function . ,Text_spanner::print)
1101 (font-shape . italic)
1102 (style . dashed-line)
1103 (staff-padding . 0.1)
1105 ;; urg, only for (de)cresc. text spanners
1106 (if-text-padding . 1.0)
1107 (dash-fraction . 0.2)
1110 (meta . ((interfaces . (text-spanner-interface side-position-interface font-interface spanner-interface))))
1115 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1116 (print-function . ,Ottava_bracket::print)
1117 (font-shape . italic)
1118 (shorten-pair . (0.0 . -0.6))
1119 (staff-padding . 1.0)
1121 (minimum-length . 1.0)
1122 (dash-fraction . 0.3)
1123 (edge-height . (0 . 1.2))
1125 (meta . ((interfaces . (ottava-bracket-interface
1126 line-interface side-position-interface
1127 font-interface text-interface spanner-interface))))
1133 (print-function . ,Text_item::print)
1134 (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
1135 (extra-offset . (0 . -0.65)) ;; UGH! TODO: Clean this up!
1136 (stem-attachment-function . ,tablature-stem-attachment-function)
1137 (meta . ((interfaces
1138 . (rhythmic-head-interface
1140 note-head-interface staff-symbol-referencer-interface
1141 text-interface item-interface ))))
1147 (print-function . ,Tie::print)
1148 (spacing-procedure . ,Spanner::set_spacing_rods)
1149 (staffline-clearance . 0.35)
1150 (details . ((ratio . 0.333) (height-limit . 1.0)))
1154 (minimum-length . 2.5)
1155 (meta . ((interfaces . (tie-interface spanner-interface))))
1160 (after-line-breaking-callback . ,Tie_column::after_line_breaking)
1161 (X-extent-callback . #f)
1162 (Y-extent-callback . #f)
1163 (meta . ((interfaces . (tie-column-interface spanner-interface))))
1168 (print-function . ,Time_signature::print)
1169 ; (print-function . ,Text_item::print)
1170 (break-align-symbol . time-signature)
1171 (break-visibility . ,all-visible)
1173 (first-note . (fixed-space . 2.0))
1174 (right-edge . (extra-space . 0.5))
1175 (staff-bar . (minimum-space . 2.0))
1179 ; (text . (,time-signature-glue-markup))
1180 (meta . ((interfaces . (time-signature-interface break-aligned-interface font-interface item-interface ))))
1188 (edge-height . (0.7 . 0.7))
1189 (shorten-pair . (-0.2 . -0.2))
1190 (before-line-breaking-callback . ,Tuplet_bracket::before_line_breaking)
1191 (after-line-breaking-callback . ,Tuplet_bracket::after_line_breaking)
1192 (print-function . ,Tuplet_bracket::print)
1193 (font-shape . italic)
1194 (font-series . bold)
1197 (meta . ((interfaces . (text-interface line-interface tuplet-bracket-interface font-interface spanner-interface))))
1202 (print-function . ,Text_item::print)
1203 (font-shape . italic)
1204 (no-spacing-rods . #t)
1205 (self-alignment-X . 0)
1207 (padding . 0.0) ;; padding relative to UnaCordaPedalLineSpanner
1208 (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1209 (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface ))))
1212 (UnaCordaPedalLineSpanner
1215 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1216 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1218 (staff-padding . 1.2)
1219 (minimum-space . 1.0)
1221 (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1228 (ligature-primitive-callback . ,Vaticana_ligature::brew_ligature_primitive)
1229 (print-function . ,Vaticana_ligature::print)
1230 (meta . ((interfaces . (vaticana-ligature-interface font-interface))))
1235 (print-function . ,Volta_bracket_interface::print)
1238 (font-encoding . number)
1239 (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1240 (thickness . 1.6) ; linethickness
1241 (height . 2.0) ; staffspace;
1244 (meta . ((interfaces . (volta-bracket-interface line-interface text-interface side-position-interface font-interface spanner-interface))))
1250 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1251 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1253 (meta . ((interfaces . (align-interface axis-group-interface spanner-interface))))
1259 (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1260 (X-extent-callback . ,Axis_group_interface::group_extent_callback)
1262 (meta . ((interfaces . (axis-group-interface spanner-interface))))
1270 (define (completize-grob-entry x)
1271 "transplant assoc key into 'name entry of 'meta of X
1273 (let* ((name-sym (car x))
1274 (grob-entry (cdr x))
1275 (metaentry (cdr (assoc 'meta grob-entry)))
1277 (cdr (assoc 'interfaces metaentry)))
1280 (set! metaentry (assoc-set! metaentry 'name name-sym))
1281 (set! metaentry (assoc-set! metaentry 'interfaces
1282 (cons 'grob-interface ifaces-entry)))
1283 (set! grob-entry (assoc-set! grob-entry 'meta metaentry))
1284 (cons name-sym grob-entry)))
1286 (set! all-grob-descriptions (map completize-grob-entry all-grob-descriptions))
1290 ; (display (map pair? all-grob-descriptions))
1293 ;; make sure that \property Foo.Bar =\turnOff doesn't complain
1296 ; (display (car x)) (newline)
1298 (set-object-property! (car x) 'translation-type? list?)
1299 (set-object-property! (car x) 'is-grob? #t))
1300 all-grob-descriptions)
1303 (set! all-grob-descriptions (sort all-grob-descriptions alist<?))