]> git.donarmstrong.com Git - lilypond.git/blob - scm/define-grobs.scm
Add commands \markLengthOn \markLengthOff; issue 3279
[lilypond.git] / scm / define-grobs.scm
1 ;;;; This file is part of LilyPond, the GNU music typesetter.
2 ;;;;
3 ;;;; Copyright (C) 1998--2012 Han-Wen Nienhuys <hanwen@xs4all.nl>
4 ;;;;                 Jan Nieuwenhuizen <janneke@gnu.org>
5 ;;;;
6 ;;;; LilyPond is free software: you can redistribute it and/or modify
7 ;;;; it under the terms of the GNU General Public License as published by
8 ;;;; the Free Software Foundation, either version 3 of the License, or
9 ;;;; (at your option) any later version.
10 ;;;;
11 ;;;; LilyPond is distributed in the hope that it will be useful,
12 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
13 ;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 ;;;; GNU General Public License for more details.
15 ;;;;
16 ;;;; You should have received a copy of the GNU General Public License
17 ;;;; along with LilyPond.  If not, see <http://www.gnu.org/licenses/>.
18
19 ;;;; distances are given in line-thickness (thicknesses) and
20 ;;;; staff-space (distances)
21
22 ;;;; WARNING: the meta field should be the last one.
23 ;;;; WARNING: don't use anonymous functions for initialization.
24
25 ;; TODO: junk the meta field in favor of something more compact?
26
27
28 (define-public all-grob-descriptions
29   `(
30     (Accidental
31      . (
32         (alteration . ,accidental-interface::calc-alteration)
33         (avoid-slur . inside)
34         (glyph-name . ,accidental-interface::glyph-name)
35         (glyph-name-alist . ,standard-alteration-glyph-name-alist)
36         (stencil . ,ly:accidental-interface::print)
37         (horizontal-skylines . ,(ly:make-unpure-pure-container ly:accidental-interface::horizontal-skylines))
38         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
39         (X-extent . ,ly:accidental-interface::width)
40         (Y-extent . ,accidental-interface::height)
41         (meta . ((class . Item)
42                  (interfaces . (accidental-interface
43                                 inline-accidental-interface
44                                 font-interface))))))
45
46     (AccidentalCautionary
47      . (
48         (alteration . ,accidental-interface::calc-alteration)
49         (avoid-slur . inside)
50         (glyph-name-alist . ,standard-alteration-glyph-name-alist)
51         (parenthesized . #t)
52         (stencil . ,ly:accidental-interface::print)
53         (Y-extent . ,accidental-interface::height)
54         (meta . ((class . Item)
55                  (interfaces . (accidental-interface
56                                 inline-accidental-interface
57                                 font-interface))))))
58
59     (AccidentalPlacement
60      . (
61         (direction .  ,LEFT)
62         (positioning-done . ,ly:accidental-placement::calc-positioning-done)
63
64         ;; this is quite small, but it is very ugly to have
65         ;; accs closer to the previous note than to the next one.
66         (right-padding . 0.15)
67
68         ;; for horizontally stacked scripts.
69         (script-priority .  -100)
70
71         (X-extent . ,ly:axis-group-interface::width)
72         (meta . ((class . Item)
73                  (interfaces . (accidental-placement-interface))))))
74
75     (AccidentalSuggestion
76      . (
77         (alteration . ,accidental-interface::calc-alteration)
78         (direction . ,UP)
79         (font-size . -2)
80         (glyph-name-alist . ,standard-alteration-glyph-name-alist)
81         (outside-staff-priority . 0)
82         (script-priority . 0)
83         (self-alignment-X . ,CENTER)
84         (side-axis . ,Y)
85         (staff-padding . 0.25)
86         (stencil . ,ly:accidental-interface::print)
87         (X-extent . ,ly:accidental-interface::width)
88         (X-offset . ,(ly:make-simple-closure
89                       `(,+
90                         ,(ly:make-simple-closure
91                           (list ly:self-alignment-interface::centered-on-x-parent))
92                         ,(ly:make-simple-closure
93                           (list ly:self-alignment-interface::x-aligned-on-self)))))
94         (Y-extent . ,accidental-interface::height)
95         (Y-offset . ,side-position-interface::y-aligned-side)
96         (meta . ((class . Item)
97                  (interfaces . (accidental-interface
98                                 accidental-suggestion-interface
99                                 font-interface
100                                 script-interface
101                                 self-alignment-interface
102                                 side-position-interface))))))
103
104     (Ambitus
105      . (
106         (axes . (,X ,Y))
107         (break-align-symbol . ambitus)
108         (break-visibility . ,begin-of-line-visible)
109         (non-musical . #t)
110         (space-alist . (
111                         (cue-end-clef . (extra-space . 0.5))
112                         (clef . (extra-space . 0.5))
113                         (cue-clef . (extra-space . 0.5))
114                         (key-signature . (extra-space . 0.0))
115                         (staff-bar . (extra-space . 0.0))
116                         (time-signature . (extra-space . 0.0))
117                         (first-note . (fixed-space . 0.0))))
118         (X-extent . ,ly:axis-group-interface::width)
119         (Y-extent . ,axis-group-interface::height)
120         (meta . ((class . Item)
121                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
122                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
123                  (interfaces . (ambitus-interface
124                                 axis-group-interface
125                                 break-aligned-interface))))))
126
127     (AmbitusAccidental
128      . (
129         (direction . ,LEFT)
130         (glyph-name-alist . ,standard-alteration-glyph-name-alist)
131         (padding . 0.5)
132         (side-axis . ,X)
133         (stencil . ,ly:accidental-interface::print)
134         (X-offset . ,ly:side-position-interface::x-aligned-side)
135         (Y-extent . ,accidental-interface::height)
136         (meta . ((class . Item)
137                  (interfaces . (accidental-interface
138                                 break-aligned-interface
139                                 font-interface
140                                 side-position-interface))))))
141
142     (AmbitusLine
143      . (
144         (gap . 0.35)
145         (stencil . ,ambitus::print)
146         (thickness . 2)
147         (X-offset . ,ly:self-alignment-interface::centered-on-x-parent)
148         (meta . ((class . Item)
149                  (interfaces . (ambitus-interface
150                                 font-interface))))))
151
152     (AmbitusNoteHead
153      . (
154         (duration-log . 2)
155         (glyph-name . ,note-head::calc-glyph-name)
156         (stencil . ,ly:note-head::print)
157         (Y-offset . ,staff-symbol-referencer::callback)
158         (Y-extent . ,grob::always-Y-extent-from-stencil)
159         (meta . ((class . Item)
160                  (interfaces . (ambitus-interface
161                                 font-interface
162                                 ledgered-interface
163                                 note-head-interface
164                                 rhythmic-head-interface
165                                 staff-symbol-referencer-interface))))))
166
167     (Arpeggio
168      . (
169         (direction . ,LEFT)
170         (padding . 0.5)
171         (positions . ,ly:arpeggio::calc-positions)
172         (protrusion . 0.4)
173         (script-priority . 0)
174         (side-axis . ,X)
175         (staff-position . 0.0)
176         (stencil . ,ly:arpeggio::print)
177         (X-extent . ,ly:arpeggio::width)
178         (Y-extent . ,(grob::unpure-Y-extent-from-stencil ly:arpeggio::pure-height))
179         (X-offset . ,ly:side-position-interface::x-aligned-side)
180         (Y-offset . ,staff-symbol-referencer::callback)
181         (meta . ((class . Item)
182                  (interfaces . (arpeggio-interface
183                                 font-interface
184                                 side-position-interface
185                                 staff-symbol-referencer-interface))))))
186
187     (BalloonTextItem
188      . (
189         (annotation-balloon . #t)
190         (annotation-line . #t)
191         (stencil . ,ly:balloon-interface::print)
192         (text . ,(grob::calc-property-by-copy 'text))
193         (X-offset . ,(grob::calc-property-by-copy 'X-offset))
194         (Y-offset . ,(grob::calc-property-by-copy 'Y-offset))
195         (meta . ((class . Item)
196                  (interfaces . (balloon-interface
197                                 font-interface
198                                 text-interface))))))
199
200     (BarLine
201      . (
202         (allow-span-bar . #t)
203         (bar-extent . ,ly:bar-line::calc-bar-extent)
204         (break-align-anchor . ,ly:bar-line::calc-anchor)
205         (break-align-symbol . staff-bar)
206         (break-visibility . ,bar-line::calc-break-visibility)
207         (extra-spacing-height . ,pure-from-neighbor-interface::account-for-span-bar)
208         (gap . 0.4)
209         (glyph . "|")
210         (glyph-name . ,bar-line::calc-glyph-name)
211
212         ;;
213         ;; Ross. page 151 lists other values, we opt for a leaner look
214         ;;
215         ;; TODO:
216         ;; kern should scale with line-thickness too.
217         (kern . 3.0)
218         (thin-kern . 3.0)
219         (hair-thickness . 1.9)
220         (thick-thickness . 6.0)
221
222         (layer . 0)
223         (non-musical . #t)
224         (rounded . #f)
225         (space-alist . (
226                         (time-signature . (extra-space . 0.75))
227                         (custos . (minimum-space . 2.0))
228                         (clef . (minimum-space . 1.0))
229                         (key-signature . (extra-space . 1.0))
230                         (key-cancellation . (extra-space . 1.0))
231                         (first-note . (fixed-space . 1.3))
232                         (next-note . (semi-fixed-space . 0.9))
233                         (right-edge . (extra-space . 0.0))))
234         (stencil . ,ly:bar-line::print)
235         (Y-extent . ,grob::always-Y-extent-from-stencil)
236         (meta . ((class . Item)
237                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
238                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
239                  (interfaces . (bar-line-interface
240                                 break-aligned-interface
241                                 font-interface
242                                 pure-from-neighbor-interface))))))
243
244     (BarNumber
245      . (
246         (after-line-breaking . ,ly:side-position-interface::move-to-extremal-staff)
247         ;; want the bar number before the clef at line start.
248         (break-align-symbols . (left-edge staff-bar))
249
250         (break-visibility . ,begin-of-line-visible)
251         (direction . ,UP)
252         (extra-spacing-width . (+inf.0 . -inf.0))
253         (font-family . roman)
254         (font-size . -2)
255         (non-musical . #t)
256         ;; w/o padding, bars numbers are not positioned over the staff as
257         ;; they are slightly to the left. so we add just a bit.
258         (horizon-padding . 0.05)
259         (outside-staff-priority . 100)
260         (padding . 1.0)
261         (self-alignment-X . ,RIGHT)
262         (side-axis . ,Y)
263         (stencil . ,ly:text-interface::print)
264         (X-offset . ,(ly:make-simple-closure
265                       `(,+
266                         ,(ly:make-simple-closure
267                           (list ly:break-alignable-interface::self-align-callback))
268                         ,(ly:make-simple-closure
269                           (list ly:self-alignment-interface::x-aligned-on-self)))))
270         (Y-offset . ,side-position-interface::y-aligned-side)
271         (Y-extent . ,grob::always-Y-extent-from-stencil)
272         (meta .
273               ((class . Item)
274                (interfaces . (break-alignable-interface
275                               font-interface
276                               self-alignment-interface
277                               side-position-interface
278                               text-interface))))))
279
280     (BassFigure
281      . (
282         (stencil . ,ly:text-interface::print)
283         (Y-extent . ,grob::always-Y-extent-from-stencil)
284         (meta . ((class . Item)
285                  (interfaces . (bass-figure-interface
286                                 font-interface
287                                 rhythmic-grob-interface
288                                 text-interface))))))
289
290     (BassFigureAlignment
291      . (
292         (axes . (,Y))
293         (padding . 0.2)
294         (positioning-done . ,ly:align-interface::align-to-minimum-distances)
295         (stacking-dir . ,DOWN)
296         (X-extent . ,ly:axis-group-interface::width)
297         (Y-extent . ,axis-group-interface::height)
298         (meta . ((class . Spanner)
299                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
300                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
301                  (interfaces . (align-interface
302                                 axis-group-interface
303                                 bass-figure-alignment-interface))))))
304
305     (BassFigureAlignmentPositioning
306      . (
307         (axes . (,Y))
308         (direction . ,UP)
309         (padding . 0.5)
310         (side-axis . ,Y)
311         (staff-padding . 1.0)
312         (X-extent . ,ly:axis-group-interface::width)
313         (Y-extent . ,axis-group-interface::height)
314         (Y-offset . ,side-position-interface::y-aligned-side)
315         (meta . ((class . Spanner)
316                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
317                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
318                  (interfaces . (axis-group-interface
319                                 side-position-interface))))))
320
321     (BassFigureBracket
322      . (
323         (edge-height . (0.2 . 0.2))
324         (stencil . ,ly:enclosing-bracket::print)
325         (X-extent . ,ly:enclosing-bracket::width)
326         (meta . ((class . Item)
327                  (interfaces . (enclosing-bracket-interface))))))
328
329     (BassFigureContinuation
330      . (
331         (stencil . ,ly:figured-bass-continuation::print)
332         (Y-offset . ,ly:figured-bass-continuation::center-on-figures)
333         (meta . ((class . Spanner)
334                  (interfaces . (figured-bass-continuation-interface))))))
335
336     (BassFigureLine
337      . (
338         (adjacent-pure-heights . ,ly:axis-group-interface::adjacent-pure-heights)
339         (axes . (,Y))
340         (vertical-skylines . ,ly:axis-group-interface::calc-skylines)
341         (X-extent . ,ly:axis-group-interface::width)
342         (Y-extent . ,axis-group-interface::height)
343         (meta . ((class . Spanner)
344                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
345                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
346                  (interfaces . (axis-group-interface))))))
347
348
349     (Beam
350      . (
351         ;; todo: clean this up a bit: the list is getting
352         ;; rather long.
353         (auto-knee-gap . 5.5)
354         (beam-segments . ,ly:beam::calc-beam-segments)
355         (beam-thickness . 0.48) ; in staff-space
356
357         ;; We have some unreferenced problems here.
358         ;;
359         ;; If we shorten beamed stems less than normal stems (1 staff-space),
360         ;; or high order less than 8th beams, patterns like
361         ;;     c''4 [c''8 c''] c''4 [c''16 c]
362         ;; are ugly (different stem lengths).
363         ;;
364         ;; But if we shorten 16th beams as much as 8th beams, a single
365         ;; forced 16th beam looks *very* short.
366
367         ;; We choose to shorten 8th beams the same as single stems,
368         ;; and high order beams less than 8th beams, so that all
369         ;; isolated shortened beams look nice and a bit shortened,
370         ;; sadly possibly breaking patterns with high order beams.
371         (beamed-stem-shorten . (1.0 0.5 0.25))
372
373         (beaming . ,ly:beam::calc-beaming)
374         (clip-edges . #t)
375         (collision-interfaces . (beam-interface
376                                  clef-interface
377                                  clef-modifier-interface
378                                  flag-interface
379                                  inline-accidental-interface
380                                  key-signature-interface
381                                  note-head-interface
382                                  stem-interface
383                                  time-signature-interface))
384         (cross-staff . ,ly:beam::calc-cross-staff)
385         (damping . 1)
386         (details
387          .(
388            (secondary-beam-demerit . 10)
389            (stem-length-demerit-factor . 5)
390            (region-size . 2)
391            (beam-eps . 0.001)
392            (stem-length-limit-penalty . 5000)
393            (damping-direction-penalty . 800)
394            (hint-direction-penalty . 20)
395            (musical-direction-factor . 400)
396            (ideal-slope-factor . 10)
397            (collision-penalty . 500)
398            (collision-padding . 0.35)
399            (round-to-zero-slope . 0.02)))
400         (direction . ,ly:beam::calc-direction)
401
402         (normalized-endpoints . ,ly:spanner::calc-normalized-endpoints)
403         ;; only for debugging.
404         (font-family . roman)
405
406         (beam-gap . ,ly:beam::calc-beam-gap)
407         (minimum-length . ,ly:beam::calc-minimum-length)
408         (neutral-direction . ,DOWN)
409         (positions . ,beam::place-broken-parts-individually)
410         (springs-and-rods . ,ly:beam::calc-springs-and-rods)
411         (X-positions . ,ly:beam::calc-x-positions)
412
413         ;; this is a hack to set stem lengths, if positions is set.
414         (quantized-positions . ,ly:beam::set-stem-lengths)
415
416         (shorten . ,ly:beam::calc-stem-shorten)
417         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
418         (stencil . ,ly:beam::print)
419
420         (meta . ((class . Spanner)
421                  (object-callbacks . ((normal-stems . ,ly:beam::calc-normal-stems)))
422                  (interfaces . (beam-interface
423                                 font-interface
424                                 staff-symbol-referencer-interface
425                                 unbreakable-spanner-interface))))))
426
427     (BendAfter
428      . (
429         (minimum-length . 0.5)
430         (stencil . ,bend::print)
431         (thickness . 2.0)
432         (meta . ((class . Spanner)
433                  (interfaces . (bend-after-interface
434                                 spanner-interface))))))
435
436     (BreakAlignGroup
437      . (
438         (axes . (,X))
439         (break-align-anchor . ,ly:break-aligned-interface::calc-average-anchor)
440         (break-visibility . ,ly:break-aligned-interface::calc-break-visibility)
441         (X-extent . ,ly:axis-group-interface::width)
442         (meta . ((class . Item)
443                  (interfaces . (axis-group-interface
444                                 break-aligned-interface))))))
445
446     (BreakAlignment
447      . (
448         (axes . (,X))
449         (break-align-orders . ;; end of line
450                             #((
451                                left-edge
452                                cue-end-clef
453                                ambitus
454                                breathing-sign
455                                clef
456                                cue-clef
457                                staff-bar
458                                key-cancellation
459                                key-signature
460                                time-signature
461                                custos)
462
463                               ;; unbroken
464                               (
465                                left-edge
466                                cue-end-clef
467                                ambitus
468                                breathing-sign
469                                clef
470                                cue-clef
471                                staff-bar
472                                key-cancellation
473                                key-signature
474                                time-signature
475                                custos)
476
477                               ;; begin of line
478                               (
479                                left-edge
480                                ambitus
481                                breathing-sign
482                                clef
483                                key-cancellation
484                                key-signature
485                                time-signature
486                                staff-bar
487                                cue-clef
488                                custos)))
489         (non-musical . #t)
490         (positioning-done . ,ly:break-alignment-interface::calc-positioning-done)
491         (stacking-dir . 1)
492         (X-extent . ,ly:axis-group-interface::width)
493         (meta . ((class . Item)
494                  (interfaces . (axis-group-interface
495                                 break-alignment-interface))))))
496
497     (BreathingSign
498      . (
499         (break-align-symbol . breathing-sign)
500         (break-visibility . ,begin-of-line-invisible)
501         (non-musical . #t)
502         (space-alist . (
503                         (ambitus . (extra-space . 2.0))
504                         (custos . (minimum-space . 1.0))
505                         (key-signature . (minimum-space . 1.5))
506                         (time-signature . (minimum-space . 1.5))
507                         (staff-bar . (minimum-space . 1.5))
508                         (clef . (minimum-space . 2.0))
509                         (cue-clef . (minimum-space . 2.0))
510                         (cue-end-clef . (minimum-space . 2.0))
511                         (first-note . (fixed-space . 1.0)) ;huh?
512                         (right-edge . (extra-space . 0.1))))
513         (stencil . ,ly:text-interface::print)
514         (text . ,(make-musicglyph-markup "scripts.rcomma"))
515         (Y-offset . ,ly:breathing-sign::offset-callback)
516         (Y-extent . ,grob::always-Y-extent-from-stencil)
517         (meta . ((class . Item)
518                  (interfaces . (break-aligned-interface
519                                 breathing-sign-interface
520                                 font-interface
521                                 text-interface))))))
522
523     (ChordName
524      . (
525         (after-line-breaking . ,ly:chord-name::after-line-breaking)
526         (font-family . sans)
527         (font-size . 1.5)
528         (stencil . ,ly:text-interface::print)
529         (extra-spacing-height . (0.2 . -0.2))
530         (extra-spacing-width . (-0.5 . 0.5))
531         (word-space . 0.0)
532         (Y-extent . ,grob::always-Y-extent-from-stencil)
533         (meta . ((class . Item)
534                  (interfaces . (chord-name-interface
535                                 font-interface
536                                 rhythmic-grob-interface
537                                 text-interface))))))
538
539     (Clef
540      . (
541         (avoid-slur . inside)
542         (break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
543         (break-align-anchor-alignment . ,RIGHT)
544         (break-align-symbol . clef)
545         (break-visibility . ,begin-of-line-visible)
546         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-at-beginning-of-line)
547         (glyph-name . ,ly:clef::calc-glyph-name)
548         (non-musical . #t)
549         (space-alist . ((cue-clef . (extra-space . 2.0))
550                         (staff-bar . (extra-space . 0.7))
551                         (key-cancellation . (minimum-space . 3.5))
552                         (key-signature . (minimum-space . 3.5))
553                         (time-signature . (minimum-space . 4.2))
554                         (first-note . (minimum-fixed-space . 5.0))
555                         (next-note . (extra-space . 1.0))
556                         (right-edge . (extra-space . 0.5))))
557         (stencil . ,ly:clef::print)
558         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
559         (Y-offset . ,staff-symbol-referencer::callback)
560         (Y-extent . ,grob::always-Y-extent-from-stencil)
561         (meta . ((class . Item)
562                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
563                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
564                  (interfaces . (break-aligned-interface
565                                 clef-interface
566                                 font-interface
567                                 pure-from-neighbor-interface
568                                 staff-symbol-referencer-interface))))))
569
570     (ClefModifier
571      . (
572         (break-visibility . ,(grob::inherit-parent-property
573                               X 'break-visibility))
574         (font-shape . italic)
575         (font-size . -4)
576         (self-alignment-X . ,CENTER)
577         (staff-padding . 0.2)
578         (stencil . ,ly:text-interface::print)
579         (X-offset . ,(ly:make-simple-closure
580                       `(,+
581                         ,(ly:make-simple-closure
582                           (list ly:self-alignment-interface::x-aligned-on-self))
583                         ,(ly:make-simple-closure
584                           (list ly:self-alignment-interface::centered-on-x-parent)))))
585         (Y-offset . ,side-position-interface::y-aligned-side)
586         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
587         (Y-extent . ,grob::always-Y-extent-from-stencil)
588         (meta . ((class . Item)
589                  (interfaces . (clef-modifier-interface
590                                 font-interface
591                                 self-alignment-interface
592                                 side-position-interface
593                                 text-interface))))))
594
595     (ClusterSpanner
596      . (
597         (cross-staff . ,ly:cluster::calc-cross-staff)
598         (minimum-length . 0.0)
599         (padding . 0.25)
600         (springs-and-rods . ,ly:spanner::set-spacing-rods)
601         (stencil . ,ly:cluster::print)
602         (style . ramp)
603         (meta . ((class . Spanner)
604                  (interfaces . (cluster-interface))))))
605
606     (ClusterSpannerBeacon
607      . (
608         (Y-extent . ,ly:cluster-beacon::height)
609         (meta . ((class . Item)
610                  (interfaces . (cluster-beacon-interface
611                                 rhythmic-grob-interface))))))
612
613     (CombineTextScript
614      . (
615         (avoid-slur . outside)
616         (baseline-skip . 2)
617         (direction . ,UP)
618         (extra-spacing-width . (+inf.0 . -inf.0))
619         (font-series . bold)
620         (outside-staff-priority . 450)
621         (padding . 0.5)
622         (script-priority . 200)
623         (side-axis . ,Y)
624         (staff-padding . 0.5)
625         ;; todo: add X self alignment?
626         (stencil . ,ly:text-interface::print)
627         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
628         (Y-offset . ,side-position-interface::y-aligned-side)
629         (Y-extent . ,grob::always-Y-extent-from-stencil)
630         (meta . ((class . Item)
631                  (interfaces . (font-interface
632                                 side-position-interface
633                                 text-interface
634                                 text-script-interface))))))
635
636     (CueClef
637      . (
638         (avoid-slur . inside)
639         (break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
640         (break-align-symbol . cue-clef)
641         (break-visibility . ,begin-of-line-visible)
642         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-at-beginning-of-line)
643         (font-size . -4)
644         (glyph-name . ,ly:clef::calc-glyph-name)
645         (non-musical . #t)
646         (full-size-change . #t)
647         (space-alist . ((staff-bar . (minimum-space . 2.7))
648                         (key-cancellation . (minimum-space . 3.5))
649                         (key-signature . (minimum-space . 3.5))
650                         (time-signature . (minimum-space . 4.2))
651                         (custos . (minimum-space . 0.0))
652                         (first-note . (minimum-fixed-space . 3.0))
653                         (next-note . (extra-space . 1.0))
654                         (right-edge . (extra-space . 0.5))))
655         (stencil . ,ly:clef::print)
656         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
657         (Y-offset . ,staff-symbol-referencer::callback)
658         (Y-extent . ,grob::always-Y-extent-from-stencil)
659         (meta . ((class . Item)
660                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
661                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
662                  (interfaces . (break-aligned-interface
663                                 clef-interface
664                                 font-interface
665                                 pure-from-neighbor-interface
666                                 staff-symbol-referencer-interface))))))
667
668     (CueEndClef
669      . (
670         (avoid-slur . inside)
671         (break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
672         (break-align-symbol . cue-end-clef)
673         (break-visibility . ,begin-of-line-invisible)
674         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-at-beginning-of-line)
675         (font-size . -4)
676         (glyph-name . ,ly:clef::calc-glyph-name)
677         (non-musical . #t)
678         (full-size-change . #t)
679         (space-alist . ((clef . (extra-space . 0.7))
680                         (cue-clef . (extra-space . 0.7))
681                         (staff-bar . (extra-space . 0.7))
682                         (key-cancellation . (minimum-space . 3.5))
683                         (key-signature . (minimum-space . 3.5))
684                         (time-signature . (minimum-space . 4.2))
685                         (first-note . (minimum-fixed-space . 5.0))
686                         (next-note . (extra-space . 1.0))
687                         (right-edge . (extra-space . 0.5))))
688         (stencil . ,ly:clef::print)
689         (Y-offset . ,staff-symbol-referencer::callback)
690         (Y-extent . ,grob::always-Y-extent-from-stencil)
691         (meta . ((class . Item)
692                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
693                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
694                  (interfaces . (break-aligned-interface
695                                 clef-interface
696                                 font-interface
697                                 pure-from-neighbor-interface
698                                 staff-symbol-referencer-interface))))))
699
700     (Custos
701      . (
702         (break-align-symbol . custos)
703         (break-visibility . ,end-of-line-visible)
704         (neutral-direction . ,DOWN)
705         (non-musical . #t)
706         (space-alist . (
707                         (first-note . (minimum-fixed-space . 0.0))
708                         (right-edge . (extra-space . 0.1))))
709         (stencil . ,ly:custos::print)
710         (style . vaticana)
711         (Y-offset . ,staff-symbol-referencer::callback)
712         (meta . ((class . Item)
713                  (interfaces  . (break-aligned-interface
714                                  custos-interface
715                                  font-interface
716                                  staff-symbol-referencer-interface))))))
717
718     (DotColumn
719      . (
720         (axes . (,X))
721         (direction . ,RIGHT)
722         (positioning-done . ,ly:dot-column::calc-positioning-done)
723         (X-extent . ,ly:axis-group-interface::width)
724         (meta . ((class . Item)
725                  (interfaces . (axis-group-interface
726                                 dot-column-interface))))))
727
728     (Dots
729      . (
730         (avoid-slur . inside)
731         (dot-count . ,dots::calc-dot-count)
732         (staff-position . ,dots::calc-staff-position)
733         (stencil . ,ly:dots::print)
734         (Y-extent . ,grob::always-Y-extent-from-stencil)
735         (extra-spacing-height . (-0.5 . 0.5))
736         (meta . ((class . Item)
737                  (interfaces . (dots-interface
738                                 font-interface
739                                 staff-symbol-referencer-interface))))))
740
741     (DoublePercentRepeat
742      . (
743         (break-align-symbol . staff-bar)
744         (break-visibility . ,begin-of-line-invisible)
745         (dot-negative-kern . 0.75)
746         (font-encoding . fetaMusic)
747         (non-musical . #t)
748         (slash-negative-kern . 1.6)
749         (slope . 1.0)
750         (stencil . ,ly:percent-repeat-item-interface::double-percent)
751         (Y-extent . ,grob::always-Y-extent-from-stencil)
752         (thickness . 0.48)
753         (meta . ((class . Item)
754                  (interfaces . (break-aligned-interface
755                                 font-interface
756                                 percent-repeat-interface
757                                 percent-repeat-item-interface))))))
758
759     (DoublePercentRepeatCounter
760      . (
761         (direction . ,UP)
762         (font-encoding . fetaText)
763         (font-size . -2)
764         (padding . 0.2)
765         (self-alignment-X . ,CENTER)
766         (side-axis . ,Y)
767         (staff-padding . 0.25)
768         (stencil . ,ly:text-interface::print)
769         (X-offset . ,(ly:make-simple-closure
770                       `(,+
771                         ,(ly:make-simple-closure
772                           (list ly:self-alignment-interface::centered-on-y-parent))
773                         ,(ly:make-simple-closure
774                           (list ly:self-alignment-interface::x-aligned-on-self)))))
775         (Y-offset . ,side-position-interface::y-aligned-side)
776         (Y-extent . ,grob::always-Y-extent-from-stencil)
777         (meta . ((class . Item)
778                  (interfaces . (font-interface
779                                 percent-repeat-interface
780                                 percent-repeat-item-interface
781                                 self-alignment-interface
782                                 side-position-interface
783                                 text-interface))))))
784
785     (DoubleRepeatSlash
786      . (
787         (dot-negative-kern . 0.75)
788         (font-encoding . fetaMusic)
789         (slash-negative-kern . 1.6)
790         (slope . 1.0)
791         (stencil . ,ly:percent-repeat-item-interface::beat-slash)
792         (Y-extent . ,grob::always-Y-extent-from-stencil)
793         (thickness . 0.48)
794         (meta . ((class . Item)
795                  (interfaces . (font-interface
796                                 percent-repeat-interface
797                                 percent-repeat-item-interface
798                                 rhythmic-grob-interface))))))
799
800     (DynamicLineSpanner
801      . (
802         (axes . (,Y))
803         (cross-staff . ,ly:side-position-interface::calc-cross-staff)
804         (direction . ,DOWN)
805         (minimum-space . 1.2)
806         (outside-staff-priority . 250)
807         (outside-staff-padding . 0.6)
808         (padding . 0.6)
809         (side-axis . ,Y)
810         (slur-padding . 0.3)
811         (staff-padding . 0.1)
812         (vertical-skylines . ,grob::always-vertical-skylines-from-element-stencils)
813         (X-extent . ,ly:axis-group-interface::width)
814         (Y-extent . ,axis-group-interface::height)
815         (Y-offset . ,side-position-interface::y-aligned-side)
816         (meta . ((class . Spanner)
817                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
818                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
819                  (interfaces . (axis-group-interface
820                                 dynamic-interface
821                                 dynamic-line-spanner-interface
822                                 side-position-interface))))))
823
824     (DynamicText
825      . (
826
827         ;; todo.
828
829         (collision-bias . -2.0)
830         (collision-padding . 0.5)
831         (direction . ,ly:script-interface::calc-direction)
832         (extra-spacing-width . (+inf.0 . -inf.0))
833         (font-encoding . fetaText)
834         (font-series . bold)
835         (font-shape . italic)
836         (positioning-done . ,ly:script-interface::calc-positioning-done)
837         (right-padding . 0.5)
838         (self-alignment-X . ,CENTER)
839         (self-alignment-Y . ,CENTER)
840         (stencil . ,ly:text-interface::print)
841         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
842         (Y-extent . ,grob::always-Y-extent-from-stencil)
843         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
844         (Y-offset . ,self-alignment-interface::y-aligned-on-self)
845         (meta . ((class . Item)
846                  (interfaces . (dynamic-interface
847                                 dynamic-text-interface
848                                 font-interface
849                                 script-interface
850                                 self-alignment-interface
851                                 text-interface))))))
852
853     (DynamicTextSpanner
854      . (
855         (before-line-breaking . ,dynamic-text-spanner::before-line-breaking)
856         (bound-details . ((right . ((attach-dir .  ,LEFT)
857                                     (Y . 0)
858                                     (padding . 0.75)
859                                     ))
860                           (right-broken . ((attach-dir .  ,RIGHT)
861                                     (padding . 0.0)
862                                     ))
863
864                           (left . ((attach-dir .  ,LEFT)
865                                    (Y . 0)
866                                    (stencil-offset . (-0.75 . -0.5))
867                                    (padding . 0.75)
868                                    ))
869                           (left-broken . ((attach-dir .  ,RIGHT)
870                                    ))
871                           ))
872         (dash-fraction . 0.2)
873         (dash-period . 3.0)
874
875         ;; rather ugh with NCSB
876         ;; (font-series . bold)
877         (font-shape . italic)
878
879         ;; need to blend with dynamic texts.
880         (font-size . 1)
881
882         (left-bound-info . ,ly:line-spanner::calc-left-bound-info-and-text)
883
884         (minimum-length . 2.0)
885         ;; make sure the spanner doesn't get too close to notes
886         (minimum-Y-extent . (-1 . 1))
887
888         (right-bound-info . ,ly:line-spanner::calc-right-bound-info)
889         (skyline-horizontal-padding . 0.2)
890         (springs-and-rods . ,ly:spanner::set-spacing-rods)
891         (stencil . ,ly:line-spanner::print)
892         (style . dashed-line)
893         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
894         (meta . ((class . Spanner)
895                  (interfaces . (dynamic-interface
896                                 dynamic-text-spanner-interface
897                                 font-interface
898                                 line-interface
899                                 line-spanner-interface
900                                 spanner-interface
901                                 text-interface))))))
902
903
904     (Episema
905      . (
906         (bound-details . ((left . ((Y . 0)
907                                    (padding . 0)
908                                    (attach-dir . ,LEFT)
909                                    ))
910                           (right . ((Y . 0)
911                                     (padding . 0)
912                                     (attach-dir . ,RIGHT)
913                                     ))
914                           ))
915         (direction . ,UP)
916         (left-bound-info . ,ly:line-spanner::calc-left-bound-info)
917         (quantize-position . #t)
918         (right-bound-info . ,ly:line-spanner::calc-right-bound-info)
919         (side-axis . ,Y)
920         (stencil . ,ly:line-spanner::print)
921         (style . line)
922         (Y-offset . ,side-position-interface::y-aligned-side)
923         (meta . ((class . Spanner)
924                  (interfaces . (episema-interface
925                                 font-interface
926                                 line-interface
927                                 line-spanner-interface
928                                 side-position-interface))))))
929
930
931     (Fingering
932      . (
933
934         ;; sync with TextScript (?)
935         (add-stem-support . ,only-if-beamed)
936         (avoid-slur . around)
937         (cross-staff . ,script-or-side-position-cross-staff)
938         (direction . ,ly:script-interface::calc-direction)
939         (font-encoding . fetaText)
940         (font-size . -5)                ; don't overlap when next to heads.
941         (padding . 0.5)
942         (positioning-done . ,ly:script-interface::calc-positioning-done)
943         (script-priority . 100)
944         (self-alignment-X . ,CENTER)
945         (self-alignment-Y . ,CENTER)
946         (slur-padding . 0.2)
947         (staff-padding . 0.5)
948         (stencil . ,ly:text-interface::print)
949         (text . ,fingering::calc-text)
950         (Y-extent . ,grob::always-Y-extent-from-stencil)
951         (meta . ((class . Item)
952                  (interfaces . (finger-interface
953                                 font-interface
954                                 self-alignment-interface
955                                 side-position-interface
956                                 text-interface
957                                 text-script-interface))))))
958
959     (FingeringColumn
960      . (
961         (padding . 0.2)
962         (positioning-done . ,ly:fingering-column::calc-positioning-done)
963         (snap-radius . 0.3)
964         (meta . ((class . Item)
965                  (interfaces . (fingering-column-interface))))))
966
967     (Flag
968      . (
969         (glyph-name . ,ly:flag::glyph-name)
970         (stencil . ,ly:flag::print)
971         (X-extent . ,ly:flag::width)
972         (X-offset . ,ly:flag::calc-x-offset)
973         (Y-offset . ,(ly:make-unpure-pure-container ly:flag::calc-y-offset ly:flag::pure-calc-y-offset))
974         (Y-extent . ,grob::always-Y-extent-from-stencil)
975         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
976         (meta . ((class . Item)
977                  (interfaces . (flag-interface
978                                 font-interface))))))
979
980     (FootnoteItem
981      . (
982         (annotation-balloon . #f)
983         (annotation-line . #t)
984         (automatically-numbered . ,(grob::calc-property-by-copy 'automatically-numbered))
985         (break-visibility . ,(grob::inherit-parent-property
986                               X 'break-visibility))
987         (footnote . #t)
988         (footnote-text . ,(grob::calc-property-by-copy 'footnote-text))
989         (stencil . ,ly:balloon-interface::print)
990         (text . ,(grob::calc-property-by-copy 'text))
991         (X-extent . #f)
992         (Y-extent . #f)
993         (X-offset . ,(grob::calc-property-by-copy 'X-offset))
994         (Y-offset . ,(grob::calc-property-by-copy 'Y-offset))
995         (meta . ((class . Item)
996                  (interfaces . (balloon-interface
997                                 footnote-interface
998                                 font-interface
999                                 text-interface))))))
1000
1001     (FootnoteSpanner
1002      . (
1003         (annotation-balloon . #f)
1004         (annotation-line . #t)
1005         (automatically-numbered . ,(grob::calc-property-by-copy 'automatically-numbered))
1006         (footnote . #t)
1007         (footnote-text . ,(grob::calc-property-by-copy 'footnote-text))
1008         (spanner-placement . ,LEFT)
1009         (stencil . ,ly:balloon-interface::print-spanner)
1010         (text . ,(grob::calc-property-by-copy 'text))
1011         (X-extent . #f)
1012         (Y-extent . #f)
1013         (X-offset . ,(grob::calc-property-by-copy 'X-offset))
1014         (Y-offset . ,(grob::calc-property-by-copy 'Y-offset))
1015         (meta . ((class . Spanner)
1016                  (interfaces . (balloon-interface
1017                                 footnote-interface
1018                                 footnote-spanner-interface
1019                                 font-interface
1020                                 text-interface))))))
1021
1022     (FretBoard
1023      . (
1024         (after-line-breaking . ,ly:chord-name::after-line-breaking)
1025         (fret-diagram-details . ((finger-code . below-string)))
1026         (stencil . ,fret-board::calc-stencil)
1027         (extra-spacing-height . (0.2 . -0.2))
1028         (extra-spacing-width . (-0.5 . 0.5))
1029         (Y-extent . ,grob::always-Y-extent-from-stencil)
1030         (meta . ((class . Item)
1031                  (interfaces . (chord-name-interface
1032                                 font-interface
1033                                 fret-diagram-interface
1034                                 rhythmic-grob-interface))))))
1035
1036
1037     (Glissando
1038      . (
1039         (after-line-breaking . ,ly:spanner::kill-zero-spanned-time)
1040         (bound-details . ((right . ((attach-dir .  ,LEFT)
1041                                     (end-on-accidental . #t)
1042                                     (padding . 0.5)
1043                                       ))
1044                           (left . ((attach-dir .  ,RIGHT)
1045                                    (padding . 0.5)
1046                                       ))
1047                           ))
1048         (cross-staff . ,ly:line-spanner::calc-cross-staff)
1049         (gap . 0.5)
1050         (left-bound-info . ,ly:line-spanner::calc-left-bound-info)
1051         (normalized-endpoints . ,ly:spanner::calc-normalized-endpoints)
1052         (right-bound-info . ,ly:line-spanner::calc-right-bound-info)
1053         (simple-Y . #t)
1054         (stencil . ,ly:line-spanner::print)
1055         (style . line)
1056         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1057         (X-extent . #f)
1058         (Y-extent . #f)
1059         (zigzag-width . 0.75)
1060         (meta . ((class . Spanner)
1061                  (interfaces . (glissando-interface
1062                                 line-interface
1063                                 line-spanner-interface
1064                                 unbreakable-spanner-interface))))))
1065
1066     (GraceSpacing
1067      . (
1068         (common-shortest-duration . ,grace-spacing::calc-shortest-duration)
1069         (shortest-duration-space . 1.6)
1070         (spacing-increment . 0.8)
1071         (meta . ((class . Spanner)
1072                  (interfaces . (grace-spacing-interface
1073                                 spacing-options-interface
1074                                 spanner-interface))))))
1075
1076     (GridLine
1077      . (
1078         (layer . 0)
1079         (self-alignment-X . ,CENTER)
1080         (stencil . ,ly:grid-line-interface::print)
1081         (X-extent  . ,ly:grid-line-interface::width)
1082         (X-offset . ,(ly:make-simple-closure
1083                       `(,+
1084                         ,(ly:make-simple-closure
1085                           (list ly:self-alignment-interface::centered-on-x-parent))
1086                         ,(ly:make-simple-closure
1087                           (list ly:self-alignment-interface::x-aligned-on-self)))))
1088         (meta . ((class . Item)
1089                  (interfaces . (grid-line-interface
1090                                 self-alignment-interface))))))
1091
1092     (GridPoint
1093      . (
1094         (X-extent . (0 . 0))
1095         (Y-extent . (0 . 0))
1096         (meta . ((class . Item)
1097                  (interfaces . (grid-point-interface))))))
1098
1099
1100     (Hairpin
1101      . (
1102         (after-line-breaking . ,ly:spanner::kill-zero-spanned-time)
1103         (bound-padding . 1.0)
1104         (broken-bound-padding . ,ly:hairpin::broken-bound-padding)
1105         (circled-tip . #f)
1106         (grow-direction . ,hairpin::calc-grow-direction)
1107         (height . 0.6666)
1108         (minimum-length . 2.0)
1109         (self-alignment-Y . ,CENTER)
1110         (springs-and-rods . ,ly:spanner::set-spacing-rods)
1111         (stencil . ,ly:hairpin::print)
1112         (thickness . 1.0)
1113         (to-barline . #t)
1114         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1115         (Y-extent . ,(grob::unpure-Y-extent-from-stencil ly:hairpin::pure-height))
1116         (Y-offset . ,self-alignment-interface::y-aligned-on-self)
1117         (meta . ((class . Spanner)
1118                  (interfaces . (dynamic-interface
1119                                 hairpin-interface
1120                                 line-interface
1121                                 self-alignment-interface
1122                                 spanner-interface))))))
1123
1124     (HorizontalBracket
1125      . (
1126         (bracket-flare . (0.5 . 0.5))
1127         (connect-to-neighbor . ,ly:tuplet-bracket::calc-connect-to-neighbors)
1128         (direction . ,DOWN)
1129         (padding . 0.2)
1130         (side-axis . ,Y)
1131         (staff-padding . 0.2)
1132         (stencil . ,ly:horizontal-bracket::print)
1133         (thickness . 1.0)
1134         (Y-offset . ,side-position-interface::y-aligned-side)
1135         (meta . ((class . Spanner)
1136                  (interfaces . (horizontal-bracket-interface
1137                                 line-interface
1138                                 side-position-interface
1139                                 spanner-interface))))))
1140
1141
1142     (InstrumentName
1143      . (
1144         (direction . ,LEFT)
1145         (padding . 0.3)
1146         (self-alignment-X . ,CENTER)
1147         (self-alignment-Y . ,CENTER)
1148         (stencil . ,system-start-text::print)
1149         (X-offset . ,system-start-text::calc-x-offset)
1150         (Y-offset . ,system-start-text::calc-y-offset)
1151         (meta . ((class . Spanner)
1152                  (interfaces . (font-interface
1153                                 self-alignment-interface
1154                                 side-position-interface
1155                                 system-start-text-interface))))))
1156
1157     (InstrumentSwitch
1158      . (
1159         (direction . ,UP)
1160         (extra-spacing-width . (+inf.0 . -inf.0))
1161         (outside-staff-priority . 500)
1162         (padding . 0.5)
1163         (self-alignment-X . ,LEFT)
1164         (side-axis . ,Y)
1165         (staff-padding . 0.5)
1166         (stencil . ,ly:text-interface::print)
1167         (Y-extent . ,grob::always-Y-extent-from-stencil)
1168         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
1169         (Y-offset . ,side-position-interface::y-aligned-side)
1170         (meta . ((class . Item)
1171                  (interfaces . (font-interface
1172                                 self-alignment-interface
1173                                 side-position-interface
1174                                 text-interface))))))
1175
1176
1177     (KeyCancellation
1178      . (
1179         (break-align-symbol . key-cancellation)
1180         (break-visibility . ,begin-of-line-invisible)
1181         (glyph-name-alist . ,cancellation-glyph-name-alist)
1182         (non-musical . #t)
1183         (flat-positions . (2 3 4 2 1 2 1))
1184         (sharp-positions . (4 5 4 2 3 2 3))
1185         (space-alist . (
1186                         (time-signature . (extra-space . 1.25))
1187                         (staff-bar . (extra-space . 0.6))
1188                         (key-signature . (extra-space . 0.5))
1189                         (cue-clef . (extra-space . 0.5))
1190                         (right-edge . (extra-space . 0.5))
1191                         (first-note . (fixed-space . 2.5))))
1192         (stencil . ,ly:key-signature-interface::print)
1193         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1194         (Y-extent . ,grob::always-Y-extent-from-stencil)
1195         (extra-spacing-width . (0.0 . 1.0))
1196         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-including-staff)
1197         (Y-offset . ,staff-symbol-referencer::callback)
1198         (meta . ((class . Item)
1199                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1200                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
1201                  (interfaces . (break-aligned-interface
1202                                 font-interface
1203                                 key-cancellation-interface
1204                                 key-signature-interface
1205                                 pure-from-neighbor-interface
1206                                 staff-symbol-referencer-interface))))))
1207
1208     (KeySignature
1209      . (
1210         (avoid-slur . inside)
1211         (break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
1212         (break-align-anchor-alignment . ,RIGHT)
1213         (break-align-symbol . key-signature)
1214         (break-visibility . ,begin-of-line-visible)
1215         (glyph-name-alist . ,standard-alteration-glyph-name-alist)
1216         (non-musical . #t)
1217         (flat-positions . (2 3 4 2 1 2 1))
1218         (sharp-positions . (4 5 4 2 3 2 3))
1219         (space-alist . (
1220                         (time-signature . (extra-space . 1.15))
1221                         (staff-bar . (extra-space . 1.1))
1222                         (cue-clef . (extra-space . 0.5))
1223                         (right-edge . (extra-space . 0.5))
1224                         (first-note . (fixed-space . 2.5))))
1225         (stencil . ,ly:key-signature-interface::print)
1226         (Y-extent . ,grob::always-Y-extent-from-stencil)
1227         (extra-spacing-width . (0.0 . 1.0))
1228         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-including-staff)
1229         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1230         (Y-offset . ,staff-symbol-referencer::callback)
1231         (meta . ((class . Item)
1232                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1233                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
1234                  (interfaces . (break-aligned-interface
1235                                 font-interface
1236                                 key-signature-interface
1237                                 pure-from-neighbor-interface
1238                                 staff-symbol-referencer-interface))))))
1239
1240     (KievanLigature
1241      . (
1242         (springs-and-rods . ,ly:spanner::set-spacing-rods)
1243         (stencil . ,ly:kievan-ligature::print)
1244         (padding . 0.5)
1245         (meta . ((class . Spanner)
1246                  (interfaces . (font-interface
1247                                 kievan-ligature-interface))))))
1248
1249    (LaissezVibrerTie
1250      . (
1251         (control-points . ,ly:semi-tie::calc-control-points)
1252         (cross-staff . ,semi-tie::calc-cross-staff)
1253         (details . ((ratio . 0.333)
1254                     (height-limit . 1.0)))
1255         (direction . ,ly:tie::calc-direction)
1256         (head-direction . ,LEFT)
1257         (stencil  . ,laissez-vibrer::print)
1258         (thickness . 1.0)
1259         (extra-spacing-height . (-0.5 . 0.5))
1260         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1261         (Y-extent . ,grob::always-Y-extent-from-stencil)
1262         (meta . ((class . Item)
1263                  (interfaces . (semi-tie-interface))))))
1264
1265     (LaissezVibrerTieColumn
1266      . (
1267         (head-direction . ,ly:semi-tie-column::calc-head-direction)
1268         (positioning-done . ,ly:semi-tie-column::calc-positioning-done)
1269         (X-extent . #f)
1270         (Y-extent . #f)
1271         (meta . ((class . Item)
1272                  (interfaces . (semi-tie-column-interface))))))
1273
1274     (LedgerLineSpanner
1275      . (
1276         (layer . 0)
1277         (length-fraction . 0.25)
1278         (minimum-length-fraction . 0.25)
1279         (springs-and-rods . ,ly:ledger-line-spanner::set-spacing-rods)
1280         (stencil . ,ly:ledger-line-spanner::print)
1281         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1282         (X-extent . #f)
1283         (Y-extent . #f)
1284         (meta . ((class . Spanner)
1285                  (interfaces . (ledger-line-spanner-interface))))))
1286
1287     (LeftEdge
1288      . (
1289         (break-align-anchor . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
1290         (break-align-symbol . left-edge)
1291         (break-visibility . ,center-invisible)
1292         (non-musical . #t)
1293         (extra-spacing-height . (+inf.0 . -inf.0))
1294         (space-alist . (
1295                         (ambitus . (extra-space . 2.0))
1296                         (breathing-sign . (minimum-space . 0.0))
1297                         (cue-end-clef . (extra-space . 0.8))
1298                         (clef . (extra-space . 0.8))
1299                         (cue-clef . (extra-space . 0.8))
1300                         (staff-bar . (extra-space . 0.0))
1301                         (key-cancellation . (extra-space . 0.0))
1302                         (key-signature . (extra-space . 0.8))
1303                         (time-signature . (extra-space . 1.0))
1304                         (custos . (extra-space . 0.0))
1305                         (first-note . (fixed-space . 2.0))
1306                         (right-edge . (extra-space . 0.0))
1307                         ))
1308         (X-extent . (0 . 0))
1309         (meta . ((class . Item)
1310                  (interfaces . (break-aligned-interface))))))
1311
1312     (LigatureBracket
1313      . (
1314         ;; ugh.  A ligature bracket is totally different from
1315         ;; a tuplet bracket.
1316
1317         (bracket-visibility . #t)
1318         (connect-to-neighbor . ,ly:tuplet-bracket::calc-connect-to-neighbors)
1319         (direction . ,UP)
1320         (edge-height . (0.7 . 0.7))
1321         (padding . 2.0)
1322         (positions . ,ly:tuplet-bracket::calc-positions)
1323         (shorten-pair . (-0.2 . -0.2))
1324         (staff-padding . 0.25)
1325         (stencil . ,ly:tuplet-bracket::print)
1326         (thickness . 1.6)
1327         (X-positions . ,ly:tuplet-bracket::calc-x-positions)
1328         (meta . ((class . Spanner)
1329                  (interfaces . (line-interface
1330                                 tuplet-bracket-interface))))))
1331
1332     (LyricExtender
1333      . (
1334         (minimum-length . 1.5)
1335         (stencil . ,ly:lyric-extender::print)
1336         (thickness . 0.8) ; line-thickness
1337         (Y-extent . (0 . 0))
1338         (meta . ((class . Spanner)
1339                  (interfaces . (lyric-extender-interface
1340                                 lyric-interface))))))
1341
1342     (LyricHyphen
1343      . (
1344         (after-line-breaking . ,ly:spanner::kill-zero-spanned-time)
1345         (dash-period . 10.0)
1346         (height . 0.42)
1347         (length . 0.66)
1348         (minimum-distance . 0.1)
1349         (minimum-length . 0.3)
1350         (padding . 0.07)
1351         (springs-and-rods . ,ly:lyric-hyphen::set-spacing-rods)
1352         (stencil . ,ly:lyric-hyphen::print)
1353         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1354         (thickness . 1.3)
1355         (Y-extent . (0 . 0))
1356         (meta . ((class . Spanner)
1357                  (interfaces . (font-interface
1358                                 lyric-hyphen-interface
1359                                 lyric-interface
1360                                 spanner-interface))))))
1361
1362     (LyricSpace
1363      . (
1364         (minimum-distance . 0.45)
1365         (padding . 0.0)
1366         (springs-and-rods . ,ly:lyric-hyphen::set-spacing-rods)
1367         (X-extent . #f)
1368         (Y-extent . #f)
1369         (meta . ((class . Spanner)
1370                  (interfaces . (lyric-hyphen-interface
1371                                 spanner-interface))))))
1372
1373     (LyricText
1374      . (
1375         (extra-spacing-width . (0.0 . 0.0))
1376         ;; Recede in height for purposes of note spacing,
1377         ;; so notes in melismata can be freely spaced above lyrics
1378         (extra-spacing-height . (0.2 . -0.2))
1379         (font-series . medium)
1380         (font-size . 1.0)
1381         (self-alignment-X . ,CENTER)
1382         (stencil . ,lyric-text::print)
1383         (text . ,(grob::calc-property-by-copy 'text))
1384         (word-space . 0.6)
1385         (skyline-horizontal-padding . 0.1)
1386         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1387         (X-offset . ,ly:self-alignment-interface::aligned-on-x-parent)
1388         (Y-extent . ,grob::always-Y-extent-from-stencil)
1389         (meta . ((class . Item)
1390                  (interfaces . (font-interface
1391                                 lyric-syllable-interface
1392                                 rhythmic-grob-interface
1393                                 self-alignment-interface
1394                                 text-interface))))))
1395
1396     (MeasureCounter
1397      . (
1398         (count-from . 1)
1399         (direction . ,UP)
1400         (font-encoding . fetaText)
1401         (font-size . -2)
1402         (outside-staff-horizontal-padding . 0.5)
1403         (outside-staff-padding . 0.5)
1404         (outside-staff-priority . 750)
1405         (self-alignment-X . ,CENTER)
1406         (side-axis . ,Y)
1407         (staff-padding . 0.5)
1408         (stencil . ,measure-counter-stencil)
1409         (meta . ((class . Spanner)
1410                  (interfaces . (font-interface
1411                                 measure-counter-interface
1412                                 self-alignment-interface
1413                                 side-position-interface
1414                                 text-interface))))))
1415
1416     (MeasureGrouping
1417      . (
1418         (direction . ,UP)
1419         (height . 2.0)
1420         (padding . 2)
1421         (side-axis . ,Y)
1422         (staff-padding . 3)
1423         (stencil . ,ly:measure-grouping::print)
1424         (thickness . 1)
1425         (Y-offset . ,side-position-interface::y-aligned-side)
1426         (meta . ((class . Spanner)
1427                  (interfaces . (measure-grouping-interface
1428                                 side-position-interface))))))
1429
1430     (MelodyItem
1431      . (
1432         (neutral-direction . ,DOWN)
1433         (meta . ((class . Item)
1434                  (interfaces . (melody-spanner-interface))))))
1435
1436     (MensuralLigature
1437      . (
1438         (springs-and-rods . ,ly:spanner::set-spacing-rods)
1439         (stencil . ,ly:mensural-ligature::print)
1440         (thickness . 1.3)
1441         (meta . ((class . Spanner)
1442                  (interfaces . (font-interface
1443                                 mensural-ligature-interface))))))
1444
1445     (MetronomeMark
1446      . (
1447         (after-line-breaking . ,ly:side-position-interface::move-to-extremal-staff)
1448         (break-visibility . ,end-of-line-invisible)
1449         (direction . ,UP)
1450         (extra-spacing-width . (+inf.0 . -inf.0))
1451         (outside-staff-horizontal-padding . 0.2)
1452         (outside-staff-priority . 1000)
1453         (padding . 0.8)
1454         (side-axis . ,Y)
1455         (stencil . ,ly:text-interface::print)
1456         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1457         (Y-offset . ,side-position-interface::y-aligned-side)
1458         (X-offset . ,(ly:make-simple-closure
1459                       `(,+
1460                         ,(ly:make-simple-closure
1461                           (list ly:break-alignable-interface::self-align-callback))
1462                         ,(ly:make-simple-closure
1463                           (list ly:self-alignment-interface::x-aligned-on-self)))))
1464         (self-alignment-X . ,LEFT)
1465         (break-align-symbols . (time-signature))
1466         (non-break-align-symbols . (paper-column-interface))
1467         (Y-extent . ,grob::always-Y-extent-from-stencil)
1468         (meta . ((class . Item)
1469                  (interfaces . (break-alignable-interface
1470                                 font-interface
1471                                 metronome-mark-interface
1472                                 self-alignment-interface
1473                                 side-position-interface
1474                                 text-interface))))))
1475
1476     (MultiMeasureRest
1477      . (
1478         (expand-limit . 10)
1479         (hair-thickness . 2.0)
1480         (round-up-exceptions . ())
1481         (padding . 1)
1482         (spacing-pair . (break-alignment . break-alignment))
1483         (springs-and-rods . ,ly:multi-measure-rest::set-spacing-rods)
1484         (stencil . ,ly:multi-measure-rest::print)
1485         (thick-thickness . 6.6)
1486         ;; See Wanske pp. 125
1487         (usable-duration-logs . ,(iota 4 -3))
1488         (Y-extent . ,(ly:make-unpure-pure-container ly:multi-measure-rest::height))
1489         (Y-offset . ,staff-symbol-referencer::callback)
1490         (meta . ((class . Spanner)
1491                  (interfaces . (font-interface
1492                                 multi-measure-interface
1493                                 multi-measure-rest-interface
1494                                 rest-interface
1495                                 staff-symbol-referencer-interface))))))
1496
1497     (MultiMeasureRestNumber
1498      . (
1499         (bound-padding  . 2.0)
1500         (direction . ,UP)
1501         (font-encoding . fetaText)
1502         (padding . 0.4)
1503         (self-alignment-X . ,CENTER)
1504         (side-axis . ,Y)
1505         (springs-and-rods . ,ly:multi-measure-rest::set-text-rods)
1506         (staff-padding . 0.4)
1507         (stencil . ,ly:text-interface::print)
1508         (X-offset . ,(ly:make-simple-closure
1509                       `(,+
1510                         ,(ly:make-simple-closure
1511                           (list ly:self-alignment-interface::x-aligned-on-self))
1512                         ,(ly:make-simple-closure
1513                           (list ly:self-alignment-interface::x-centered-on-y-parent)))))
1514         (Y-offset . ,side-position-interface::y-aligned-side)
1515         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1516         (Y-extent . ,grob::always-Y-extent-from-stencil)
1517         (meta . ((class . Spanner)
1518                  (interfaces . (font-interface
1519                                 multi-measure-interface
1520                                 self-alignment-interface
1521                                 side-position-interface
1522                                 text-interface))))))
1523
1524     (MultiMeasureRestText
1525      . (
1526         (direction . ,UP)
1527         (outside-staff-priority . 450)
1528         (padding . 0.2)
1529         (self-alignment-X . ,CENTER)
1530         (skyline-horizontal-padding . 0.2)
1531         (staff-padding . 0.25)
1532         (stencil . ,ly:text-interface::print)
1533         (X-offset . ,(ly:make-simple-closure
1534                       `(,+
1535                         ,(ly:make-simple-closure
1536                           (list ly:self-alignment-interface::x-centered-on-y-parent))
1537                         ,(ly:make-simple-closure
1538                           (list ly:self-alignment-interface::x-aligned-on-self)))))
1539         (Y-offset . ,side-position-interface::y-aligned-side)
1540         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1541         (Y-extent . ,grob::always-Y-extent-from-stencil)
1542         (meta . ((class . Spanner)
1543                  (interfaces . (font-interface
1544                                 multi-measure-interface
1545                                 self-alignment-interface
1546                                 side-position-interface
1547                                 text-interface))))))
1548
1549
1550     (NonMusicalPaperColumn
1551      . (
1552         (allow-loose-spacing . #t)
1553         (axes . (,X))
1554         (before-line-breaking . ,ly:paper-column::before-line-breaking)
1555         (bound-alignment-interfaces . (break-alignment-interface))
1556         (full-measure-extra-space . 1.0)
1557         (horizontal-skylines . ,ly:separation-item::calc-skylines)
1558         ;;                    (stencil . ,ly:paper-column::print)
1559
1560         (keep-inside-line . #t)
1561         (line-break-permission . allow)
1562         (non-musical . #t)
1563         (page-break-permission . allow)
1564
1565         ;; debugging stuff: print column number.
1566         ;;               (font-size . -6) (font-name . "sans")  (Y-extent . #f)
1567
1568         (X-extent . ,ly:axis-group-interface::width)
1569         (meta . ((class . Paper_column)
1570                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1571                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
1572                  (interfaces . (axis-group-interface
1573                                 font-interface
1574                                 paper-column-interface
1575                                 separation-item-interface
1576                                 spaceable-grob-interface))))))
1577
1578     (NoteCollision
1579      . (
1580         (axes . (,X ,Y))
1581         (positioning-done . ,ly:note-collision-interface::calc-positioning-done)
1582         (prefer-dotted-right . #t)
1583         (X-extent . ,ly:axis-group-interface::width)
1584         (Y-extent . ,axis-group-interface::height)
1585         (meta . ((class . Item)
1586                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1587                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
1588                  (interfaces . (axis-group-interface
1589                                 note-collision-interface))))))
1590
1591     (NoteColumn
1592      . (
1593         (axes . (,X ,Y))
1594         (bound-alignment-interfaces . (rhythmic-head-interface stem-interface))
1595         (cross-staff . ,ly:axis-group-interface::cross-staff)
1596         (horizontal-skylines . ,ly:separation-item::calc-skylines)
1597         (skyline-vertical-padding . 0.15)
1598         (X-extent . ,ly:axis-group-interface::width)
1599         (Y-extent . ,axis-group-interface::height)
1600         (meta . ((class . Item)
1601                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1602                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
1603                  (interfaces . (axis-group-interface
1604                                 note-column-interface
1605                                 separation-item-interface))))))
1606
1607     (NoteHead
1608      . (
1609         (flexa-width . 2.0)
1610         (duration-log . ,note-head::calc-duration-log)
1611         (extra-spacing-height . ,ly:note-head::include-ledger-line-height)
1612         (glyph-name . ,note-head::calc-glyph-name)
1613         (ligature-flexa . #f)
1614         (stem-attachment . ,ly:note-head::calc-stem-attachment)
1615         (stencil . ,ly:note-head::print)
1616         (X-offset . ,ly:note-head::stem-x-shift)
1617         (Y-offset . ,staff-symbol-referencer::callback)
1618         (Y-extent . ,grob::always-Y-extent-from-stencil)
1619         (meta . ((class . Item)
1620                  (interfaces . (font-interface
1621                                 gregorian-ligature-interface
1622                                 ledgered-interface
1623                                 ligature-head-interface
1624                                 mensural-ligature-interface
1625                                 note-head-interface
1626                                 rhythmic-grob-interface
1627                                 rhythmic-head-interface
1628                                 staff-symbol-referencer-interface
1629                                 vaticana-ligature-interface))))))
1630
1631     (NoteName
1632      . (
1633         (stencil . ,ly:text-interface::print)
1634         (Y-extent . ,grob::always-Y-extent-from-stencil)
1635         (meta . ((class . Item)
1636                  (interfaces . (font-interface
1637                                 note-name-interface
1638                                 text-interface))))))
1639
1640     (NoteSpacing
1641      . (
1642         ;; Changed this from 0.75.
1643         ;; If you ever change this back, please document! --hwn
1644         (knee-spacing-correction . 1.0)
1645         (same-direction-correction . 0.25)
1646         (space-to-barline . #t)
1647         (stem-spacing-correction . 0.5)
1648         (meta . ((class . Item)
1649                  (interfaces . (note-spacing-interface
1650                                 spacing-interface))))))
1651
1652     (OttavaBracket
1653      . (
1654         (dash-fraction . 0.3)
1655         (direction . ,UP)
1656         (edge-height . (0 . 1.2))
1657         (font-shape . italic)
1658         (minimum-length . 1.0)
1659         (outside-staff-priority . 400)
1660         (padding . 0.5)
1661         (shorten-pair . (0.0 . -0.6))
1662         (staff-padding . 1.0)
1663         (stencil . ,ly:ottava-bracket::print)
1664         (style . dashed-line)
1665         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1666         (Y-offset . ,side-position-interface::y-aligned-side)
1667         (meta . ((class . Spanner)
1668                  (interfaces . (font-interface
1669                                 horizontal-bracket-interface
1670                                 line-interface
1671                                 ottava-bracket-interface
1672                                 side-position-interface
1673                                 text-interface))))))
1674
1675
1676     (PaperColumn
1677      . (
1678         (allow-loose-spacing . #t)
1679         (axes . (,X))
1680         (before-line-breaking . ,ly:paper-column::before-line-breaking)
1681         (bound-alignment-interfaces . (note-column-interface))
1682         (horizontal-skylines . ,ly:separation-item::calc-skylines)
1683         (keep-inside-line . #t)
1684         ; 0.08 comes from spacing-horizontal-skyline.ly
1685         ; allows double flat of F to be nestled over dots of C
1686         (skyline-vertical-padding . 0.08)
1687         ;; (stencil . ,ly:paper-column::print)
1688         (X-extent . ,ly:axis-group-interface::width)
1689
1690         ;; debugging
1691         ;;                       (font-size . -6) (font-name . "sans") (Y-extent . #f)
1692         (meta . ((class . Paper_column)
1693                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1694                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
1695                  (interfaces . (axis-group-interface
1696                                 font-interface
1697                                 paper-column-interface
1698                                 separation-item-interface
1699                                 spaceable-grob-interface))))))
1700
1701     (ParenthesesItem
1702      . (
1703         (font-size . -6)
1704         (padding . 0.2)
1705         (stencil . ,parentheses-item::print)
1706         (stencils . ,parentheses-item::calc-parenthesis-stencils)
1707         (meta . ((class . Item)
1708                  (interfaces . (font-interface
1709                                 parentheses-interface))))))
1710
1711     (PercentRepeat
1712      . (
1713         (dot-negative-kern . 0.75)
1714         (font-encoding . fetaMusic)
1715         (slope . 1.0)
1716         (spacing-pair . (break-alignment . staff-bar))
1717         (springs-and-rods . ,ly:multi-measure-rest::set-spacing-rods)
1718         (stencil . ,ly:multi-measure-rest::percent)
1719         (thickness . 0.48)
1720         (meta . ((class . Spanner)
1721                  (interfaces . (font-interface
1722                                 multi-measure-rest-interface
1723                                 percent-repeat-interface))))))
1724
1725     (PercentRepeatCounter
1726      . (
1727         (direction . ,UP)
1728         (font-encoding . fetaText)
1729         (font-size . -2)
1730         (padding . 0.2)
1731         (self-alignment-X . ,CENTER)
1732         (staff-padding . 0.25)
1733         (stencil . ,ly:text-interface::print)
1734         (X-offset . ,(ly:make-simple-closure
1735                       `(,+
1736                         ,(ly:make-simple-closure
1737                           (list ly:self-alignment-interface::x-centered-on-y-parent))
1738                         ,(ly:make-simple-closure
1739                           (list ly:self-alignment-interface::x-aligned-on-self)))))
1740         (Y-offset . ,side-position-interface::y-aligned-side)
1741         (Y-extent . ,grob::always-Y-extent-from-stencil)
1742         (meta . ((class . Spanner)
1743                  (interfaces . (font-interface
1744                                 percent-repeat-interface
1745                                 self-alignment-interface
1746                                 side-position-interface
1747                                 text-interface))))))
1748
1749     (PhrasingSlur
1750      . (
1751         (control-points . ,ly:slur::calc-control-points)
1752         (cross-staff . ,ly:slur::calc-cross-staff)
1753         (details . ,default-slur-details)
1754         (direction . ,ly:slur::calc-direction)
1755         (height-limit . 2.0)
1756         (minimum-length . 1.5)
1757         (ratio . 0.333)
1758         (spanner-id . "")
1759         (springs-and-rods . ,ly:spanner::set-spacing-rods)
1760         (stencil . ,ly:slur::print)
1761         (thickness . 1.1)
1762         (vertical-skylines . ,(ly:make-unpure-pure-container ly:slur::vertical-skylines ly:grob::pure-simple-vertical-skylines-from-extents))
1763         (Y-extent . ,slur::height)
1764         (meta . ((class . Spanner)
1765                  (interfaces . (slur-interface))))))
1766
1767     ;; an example of a text spanner
1768     (PianoPedalBracket
1769      . (
1770         (bound-padding . 1.0)
1771         (bracket-flare . (0.5 . 0.5))
1772         (direction . ,DOWN)
1773         (edge-height . (1.0 . 1.0))
1774         (shorten-pair . (0.0 . 0.0))
1775         (stencil . ,ly:piano-pedal-bracket::print)
1776         (style . line)
1777         (thickness .  1.0)
1778         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1779         (meta . ((class . Spanner)
1780                  (interfaces . (line-interface
1781                                 piano-pedal-bracket-interface
1782                                 piano-pedal-interface))))))
1783
1784
1785     (RehearsalMark
1786      . (
1787         (after-line-breaking . ,ly:side-position-interface::move-to-extremal-staff)
1788         (baseline-skip . 2)
1789         (break-align-symbols . (staff-bar key-signature clef))
1790         (break-visibility . ,end-of-line-invisible)
1791         (direction . ,UP)
1792         (extra-spacing-width . (+inf.0 . -inf.0))
1793         (font-size . 2)
1794         (non-musical . #t)
1795         (outside-staff-horizontal-padding . 0.12)
1796         (outside-staff-priority . 1500)
1797         (padding . 0.8)
1798         (self-alignment-X . ,CENTER)
1799         (stencil . ,ly:text-interface::print)
1800         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1801         (X-offset . ,(ly:make-simple-closure
1802                       `(,+
1803                         ,(ly:make-simple-closure
1804                           (list ly:break-alignable-interface::self-align-callback))
1805                         ,(ly:make-simple-closure
1806                           (list ly:self-alignment-interface::x-aligned-on-self)))))
1807         (Y-offset . ,side-position-interface::y-aligned-side)
1808         (Y-extent . ,grob::always-Y-extent-from-stencil)
1809         (meta . ((class . Item)
1810                  (interfaces . (break-alignable-interface
1811                                 font-interface
1812                                 mark-interface
1813                                 self-alignment-interface
1814                                 side-position-interface
1815                                 text-interface))))))
1816
1817     (RepeatSlash
1818      . (
1819         (slash-negative-kern . 0.85)
1820         (slope . 1.7)
1821         (stencil . ,ly:percent-repeat-item-interface::beat-slash)
1822         (Y-extent . ,grob::always-Y-extent-from-stencil)
1823         (thickness . 0.48)
1824         (meta . ((class . Item)
1825                  (interfaces . (percent-repeat-interface
1826                                 percent-repeat-item-interface
1827                                 rhythmic-grob-interface))))))
1828
1829     (RepeatTie
1830      . (
1831         (cross-staff . ,semi-tie::calc-cross-staff)
1832         (control-points . ,ly:semi-tie::calc-control-points)
1833         (details . ((ratio . 0.333)
1834                     (height-limit . 1.0)))
1835         (direction . ,ly:tie::calc-direction)
1836         (head-direction . ,RIGHT)
1837         (stencil  . ,ly:tie::print)
1838         (thickness . 1.0)
1839         (extra-spacing-height . (-0.5 . 0.5))
1840         (Y-extent . ,grob::always-Y-extent-from-stencil)
1841         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1842         (meta . ((class . Item)
1843                  (interfaces . (semi-tie-interface))))))
1844
1845     (RepeatTieColumn
1846      . (
1847         (direction . ,ly:tie::calc-direction)
1848         (head-direction . ,ly:semi-tie-column::calc-head-direction)
1849         (positioning-done . ,ly:semi-tie-column::calc-positioning-done)
1850         (X-extent . #f)
1851         (Y-extent . #f)
1852         (meta . ((class . Item)
1853                  (interfaces . (semi-tie-column-interface))))))
1854
1855     (Rest
1856      . (
1857         (cross-staff . ,ly:rest::calc-cross-staff)
1858         (duration-log . ,stem::calc-duration-log)
1859         (minimum-distance . 0.25)
1860         (stencil . ,ly:rest::print)
1861         (X-extent . ,ly:rest::width)
1862         (Y-extent . ,(ly:make-unpure-pure-container ly:rest::height ly:rest::pure-height))
1863         (Y-offset . ,(ly:make-unpure-pure-container ly:rest::y-offset-callback))
1864         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
1865         (meta . ((class . Item)
1866                  (interfaces . (font-interface
1867                                 rest-interface
1868                                 rhythmic-grob-interface
1869                                 rhythmic-head-interface
1870                                 staff-symbol-referencer-interface))))))
1871
1872     (RestCollision
1873      . (
1874         (minimum-distance . 0.75)
1875         (positioning-done . ,ly:rest-collision::calc-positioning-done)
1876         (meta . ((class . Item)
1877                  (interfaces . (rest-collision-interface))))))
1878
1879
1880     (Script
1881      . (
1882         (add-stem-support . #t)
1883         (cross-staff . ,ly:script-interface::calc-cross-staff)
1884         (direction . ,ly:script-interface::calc-direction)
1885         (font-encoding . fetaMusic)
1886         (positioning-done . ,ly:script-interface::calc-positioning-done)
1887         (side-axis . ,Y)
1888
1889         ;; padding set in script definitions.
1890         (slur-padding . 0.2)
1891         (staff-padding . 0.25)
1892
1893         (stencil . ,ly:script-interface::print)
1894         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1895         (Y-extent . ,grob::always-Y-extent-from-stencil)
1896         (X-offset . ,script-interface::calc-x-offset)
1897         (Y-offset . ,side-position-interface::y-aligned-side)
1898         (meta . ((class . Item)
1899                  (interfaces . (font-interface
1900                                 script-interface
1901                                 side-position-interface))))))
1902
1903     (ScriptColumn
1904      . (
1905         (before-line-breaking . ,ly:script-column::before-line-breaking)
1906         (meta . ((class . Item)
1907                  (interfaces . (script-column-interface))))))
1908
1909     (ScriptRow
1910      . (
1911         (before-line-breaking . ,ly:script-column::row-before-line-breaking)
1912         (meta . ((class . Item)
1913                  (interfaces . (script-column-interface))))))
1914
1915     (Slur
1916      . (
1917         (avoid-slur . inside)
1918         (control-points . ,ly:slur::calc-control-points)
1919         (cross-staff . ,ly:slur::calc-cross-staff)
1920         (details . ,default-slur-details)
1921         (direction . ,ly:slur::calc-direction)
1922         (height-limit . 2.0)
1923         (line-thickness . 0.8)
1924         (minimum-length . 1.5)
1925         (ratio . 0.25)
1926         (spanner-id . "")
1927         (springs-and-rods . ,ly:spanner::set-spacing-rods)
1928         (stencil . ,ly:slur::print)
1929         (thickness . 1.2)
1930         (vertical-skylines . ,(ly:make-unpure-pure-container ly:slur::vertical-skylines ly:grob::pure-simple-vertical-skylines-from-extents))
1931         (Y-extent . ,slur::height)
1932         (meta . ((class . Spanner)
1933                  (interfaces . (slur-interface))))))
1934
1935     (SostenutoPedal
1936      . (
1937         (direction . ,RIGHT)
1938         (extra-spacing-width . (+inf.0 . -inf.0))
1939         (font-shape . italic)
1940         (padding . 0.0) ;; padding relative to SostenutoPedalLineSpanner
1941         (self-alignment-X . ,CENTER)
1942         (stencil . ,ly:text-interface::print)
1943         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
1944         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
1945         (Y-extent . ,grob::always-Y-extent-from-stencil)
1946         (meta . ((class . Item)
1947                  (interfaces . (font-interface
1948                                 piano-pedal-script-interface
1949                                 self-alignment-interface
1950                                 text-interface))))))
1951
1952     (SostenutoPedalLineSpanner
1953      . (
1954         (axes . (,Y))
1955         (cross-staff . ,ly:side-position-interface::calc-cross-staff)
1956         (direction . ,DOWN)
1957         (minimum-space . 1.0)
1958         (outside-staff-priority . 1000)
1959         (padding . 1.2)
1960         (side-axis . ,Y)
1961         (staff-padding . 1.0)
1962         (vertical-skylines . ,grob::always-vertical-skylines-from-element-stencils)
1963         (X-extent . ,ly:axis-group-interface::width)
1964         (Y-extent . ,axis-group-interface::height)
1965         (Y-offset . ,side-position-interface::y-aligned-side)
1966         (meta . ((class . Spanner)
1967                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
1968                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
1969                  (interfaces . (axis-group-interface
1970                                 piano-pedal-interface
1971                                 side-position-interface))))))
1972
1973     (SpacingSpanner
1974      . (
1975         (average-spacing-wishes . #t)
1976         (base-shortest-duration . ,(ly:make-moment 3 16))
1977         (common-shortest-duration . ,ly:spacing-spanner::calc-common-shortest-duration)
1978         (shortest-duration-space . 2.0)
1979         (spacing-increment . 1.2)
1980         (springs-and-rods . ,ly:spacing-spanner::set-springs)
1981         (meta . ((class . Spanner)
1982                  (interfaces . (spacing-options-interface
1983                                 spacing-spanner-interface))))))
1984
1985     (SpanBar
1986      . (
1987         (allow-span-bar . #t)
1988         (bar-extent . ,axis-group-interface::height)
1989         (before-line-breaking . ,ly:span-bar::before-line-breaking)
1990         (break-align-symbol . staff-bar)
1991         (cross-staff . #t)
1992         (glyph-name . ,ly:span-bar::calc-glyph-name)
1993         (layer . 0)
1994         (non-musical . #t)
1995         (stencil . ,ly:span-bar::print)
1996         (X-extent . ,ly:span-bar::width)
1997         (Y-extent . (+inf.0 . -inf.0))
1998         (meta . ((class . Item)
1999                  (interfaces . (bar-line-interface
2000                                 font-interface
2001                                 span-bar-interface))))))
2002
2003     (SpanBarStub
2004      . (
2005         (X-extent . ,(grob::inherit-parent-property
2006                       X 'X-extent))
2007         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height)
2008         ; we want this to be ignored, so empty, but the extra spacing height
2009         ; should preserve the span bar's presence for horizontal spacing
2010         (Y-extent . ,pure-from-neighbor-interface::height-if-pure)
2011         (meta . ((class . Item)
2012                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2013                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
2014                  (interfaces . (pure-from-neighbor-interface))))))
2015
2016     (StaffGrouper
2017      . (
2018         (staff-staff-spacing . ((basic-distance . 9)
2019                                 (minimum-distance . 7)
2020                                 (padding . 1)
2021                                 (stretchability . 5)))
2022         (staffgroup-staff-spacing . ((basic-distance . 10.5)
2023                                      (minimum-distance . 8)
2024                                      (padding . 1)
2025                                      (stretchability . 9)))
2026         (meta . ((class . Spanner)
2027                  (interfaces . (staff-grouper-interface))))))
2028
2029     (StaffSpacing
2030      . (
2031         (non-musical . #t)
2032         (stem-spacing-correction . 0.4)
2033         (meta . ((class . Item)
2034                  (interfaces . (spacing-interface
2035                                 staff-spacing-interface))))))
2036
2037     (StaffSymbol
2038      . (
2039         (layer . 0)
2040         (ledger-line-thickness . (1.0 . 0.1))
2041         (line-count . 5)
2042         (stencil . ,ly:staff-symbol::print)
2043         (Y-extent . ,(ly:make-unpure-pure-container ly:staff-symbol::height))
2044         (meta . ((class . Spanner)
2045                  (interfaces . (staff-symbol-interface))))))
2046
2047     (StanzaNumber
2048      . (
2049         (direction . ,LEFT)
2050         (font-series . bold)
2051         (padding . 1.0)
2052         (side-axis . ,X)
2053         (stencil . ,ly:text-interface::print)
2054         (X-offset . ,ly:side-position-interface::x-aligned-side)
2055         (Y-extent . ,grob::always-Y-extent-from-stencil)
2056         (meta . ((class . Item)
2057                  (interfaces . (font-interface
2058                                 side-position-interface
2059                                 stanza-number-interface
2060                                 text-interface))))))
2061
2062     (Stem
2063      . (
2064         (beamlet-default-length . (1.1 . 1.1))
2065         (beamlet-max-length-proportion . (0.75 . 0.75))
2066         (cross-staff . ,ly:stem::calc-cross-staff)
2067         (default-direction . ,ly:stem::calc-default-direction)
2068         (details
2069          . (
2070             ;; 3.5 (or 3 measured from note head) is standard length
2071             ;; 32nd, 64th, 128th flagged stems should be longer
2072             (lengths . (3.5 3.5 3.5 4.25 5.0 6.0))
2073
2074             ;; FIXME.  3.5 yields too long beams (according to Ross and
2075             ;; looking at Baerenreiter examples) for a number of common
2076             ;; boundary cases.  Subtracting half a beam thickness fixes
2077             ;; this, but the bug may well be somewhere else.
2078
2079             ;; FIXME this should come from 'lengths
2080             (beamed-lengths . (3.26 3.5 3.6))
2081
2082             ;; The 'normal' minima
2083             (beamed-minimum-free-lengths . (1.83 1.5 1.25))
2084                                         ;(beamed-minimum-free-lengths . (2.0 1.83 1.25))
2085
2086             ;; The 'extreme case' minima
2087             (beamed-extreme-minimum-free-lengths . (2.0 1.25))
2088
2089             ;; Stems in unnatural (forced) direction should be shortened by
2090             ;; one staff space, according to [Roush & Gourlay].
2091             ;; Flagged stems we shorten only half a staff space.
2092             (stem-shorten . (1.0 0.5))
2093
2094             ))
2095
2096         ;; We use the normal minima as minimum for the ideal lengths,
2097         ;; and the extreme minima as abolute minimum length.
2098
2099         (direction . ,ly:stem::calc-direction)
2100         (duration-log . ,stem::calc-duration-log)
2101         (length . ,(ly:make-unpure-pure-container ly:stem::calc-length ly:stem::pure-calc-length))
2102         (neutral-direction . ,DOWN)
2103         (positioning-done . ,ly:stem::calc-positioning-done)
2104         (stem-info . ,ly:stem::calc-stem-info)
2105         (stem-begin-position . ,(ly:make-unpure-pure-container ly:stem::calc-stem-begin-position ly:stem::pure-calc-stem-begin-position))
2106         (stencil . ,ly:stem::print)
2107         (thickness . 1.3)
2108         (X-extent . ,ly:stem::width)
2109         (X-offset . ,ly:stem::offset-callback)
2110         (Y-extent . ,(ly:make-unpure-pure-container ly:stem::height ly:stem::pure-height))
2111         (Y-offset . ,staff-symbol-referencer::callback)
2112         (meta . ((class . Item)
2113                  (interfaces . (stem-interface))))))
2114
2115     (StemStub
2116      . (
2117         (X-extent . ,stem-stub::width)
2118         (extra-spacing-height . ,stem-stub::extra-spacing-height)
2119         (Y-extent . ,(ly:make-unpure-pure-container #f stem-stub::pure-height))
2120         (meta . ((class . Item)
2121                  (interfaces . ())))))
2122
2123     (StemTremolo
2124      . (
2125         (beam-thickness . 0.48) ; staff-space
2126         (beam-width . ,ly:stem-tremolo::calc-width) ; staff-space
2127         (direction . ,ly:stem-tremolo::calc-direction)
2128         (slope . ,ly:stem-tremolo::calc-slope)
2129         (stencil . ,ly:stem-tremolo::print)
2130         (style . ,ly:stem-tremolo::calc-style)
2131         (X-extent . ,ly:stem-tremolo::width)
2132         (Y-extent . ,(grob::unpure-Y-extent-from-stencil ly:stem-tremolo::pure-height))
2133         (X-offset . ,(ly:make-simple-closure
2134                       `(,+
2135                         ,(ly:make-simple-closure
2136                           (list ly:self-alignment-interface::centered-on-x-parent))
2137                         ,(ly:make-simple-closure
2138                           (list ly:self-alignment-interface::x-aligned-on-self)))))
2139         (Y-offset . ,(ly:make-unpure-pure-container ly:stem-tremolo::calc-y-offset ly:stem-tremolo::pure-calc-y-offset))
2140         (meta . ((class . Item)
2141                  (interfaces . (self-alignment-interface
2142                                 stem-tremolo-interface))))))
2143
2144     (StringNumber
2145      . (
2146         (avoid-slur . around)
2147         (cross-staff . ,script-or-side-position-cross-staff)
2148         (font-encoding . fetaText)
2149         (font-size . -5)                ; don't overlap when next to heads.
2150         (padding . 0.5)
2151         (script-priority . 100)
2152         (self-alignment-X . ,CENTER)
2153         (self-alignment-Y . ,CENTER)
2154         (staff-padding . 0.5)
2155         (stencil . ,print-circled-text-callback)
2156         (text . ,string-number::calc-text)
2157         (Y-extent . ,grob::always-Y-extent-from-stencil)
2158         (meta . ((class . Item)
2159                  (interfaces . (font-interface
2160                                 self-alignment-interface
2161                                 side-position-interface
2162                                 string-number-interface
2163                                 text-interface
2164                                 text-script-interface))))))
2165
2166     (StrokeFinger
2167      . (
2168         (digit-names . #("p" "i" "m" "a" "x"))
2169         (font-shape . italic)
2170         (font-size . -4)                ; don't overlap when next to heads.
2171         (padding . 0.5)
2172         (script-priority . 100)
2173         (self-alignment-X . ,CENTER)
2174         (self-alignment-Y . ,CENTER)
2175         (staff-padding . 0.5)
2176         (stencil . ,ly:text-interface::print)
2177         (text . ,stroke-finger::calc-text)
2178         (Y-extent . ,grob::always-Y-extent-from-stencil)
2179         (meta . ((class . Item)
2180                  (interfaces . (font-interface
2181                                 self-alignment-interface
2182                                 side-position-interface
2183                                 stroke-finger-interface
2184                                 text-interface
2185                                 text-script-interface))))))
2186
2187     (SustainPedal
2188      . (
2189         (direction . ,RIGHT)
2190         (extra-spacing-width . (+inf.0 . -inf.0))
2191         (padding . 0.0)  ;; padding relative to SustainPedalLineSpanner
2192         (self-alignment-X . ,CENTER)
2193         (stencil . ,ly:sustain-pedal::print)
2194         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
2195         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
2196         (Y-extent . ,grob::always-Y-extent-from-stencil)
2197         (meta . ((class . Item)
2198                  (interfaces . (font-interface
2199                                 piano-pedal-interface
2200                                 piano-pedal-script-interface
2201                                 self-alignment-interface
2202                                 text-interface))))))
2203
2204     (SustainPedalLineSpanner
2205      . (
2206         (axes . (,Y))
2207         (cross-staff . ,ly:side-position-interface::calc-cross-staff)
2208         (direction . ,DOWN)
2209         (minimum-space . 1.0)
2210         (outside-staff-priority . 1000)
2211         (padding . 1.2)
2212         (side-axis . ,Y)
2213         (staff-padding . 1.2)
2214         (vertical-skylines . ,grob::always-vertical-skylines-from-element-stencils)
2215         (X-extent . ,ly:axis-group-interface::width)
2216         (Y-extent . ,axis-group-interface::height)
2217         (Y-offset . ,side-position-interface::y-aligned-side)
2218         (meta . ((class . Spanner)
2219                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2220                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
2221                  (interfaces . (axis-group-interface
2222                                 piano-pedal-interface
2223                                 side-position-interface))))))
2224
2225     (System
2226      . (
2227         (adjacent-pure-heights . ,ly:axis-group-interface::adjacent-pure-heights)
2228         (axes . (,X ,Y))
2229         (outside-staff-placement-directive . left-to-right-polite)
2230         (skyline-horizontal-padding . 1.0)
2231         (vertical-skylines . ,ly:axis-group-interface::calc-skylines)
2232         (X-extent . ,ly:axis-group-interface::width)
2233         (Y-extent . ,(ly:make-unpure-pure-container ly:system::height ly:system::calc-pure-height))
2234         (meta . ((class . System)
2235                  (object-callbacks . ((footnotes-before-line-breaking . ,ly:system::footnotes-before-line-breaking)
2236                                       (footnotes-after-line-breaking . ,ly:system::footnotes-after-line-breaking)
2237                                       (pure-relevant-grobs . ,ly:system::calc-pure-relevant-grobs)
2238                                       (pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2239                                       (vertical-skyline-elements . ,ly:system::vertical-skyline-elements)
2240                                       (vertical-alignment . ,ly:system::get-vertical-alignment)))
2241                  (interfaces . (axis-group-interface
2242                                 system-interface))))))
2243
2244     (SystemStartBar
2245      . (
2246         (collapse-height . 5.0)
2247         (direction . ,LEFT)
2248
2249         (cross-staff . #t)
2250         ;; ugh--hardcoded.
2251         (padding . -0.1)  ;; bar must cover rounded ending of staff line.
2252         (stencil . ,ly:system-start-delimiter::print)
2253         (style . bar-line)
2254         (thickness . 1.6)
2255         (X-offset . ,ly:side-position-interface::x-aligned-side)
2256         (Y-extent . #f)
2257         (meta . ((class . Spanner)
2258                  (interfaces . (side-position-interface
2259                                 system-start-delimiter-interface))))))
2260
2261     (SystemStartBrace
2262      . (
2263         (collapse-height . 5.0)
2264         (direction . ,LEFT)
2265         (font-encoding . fetaBraces)
2266         (cross-staff . #t)
2267         (padding . 0.3)
2268         (stencil . ,ly:system-start-delimiter::print)
2269         (style . brace)
2270         (X-offset . ,ly:side-position-interface::x-aligned-side)
2271         (Y-extent . #f)
2272         (meta . ((class . Spanner)
2273                  (interfaces . (font-interface
2274                                 side-position-interface
2275                                 system-start-delimiter-interface))))))
2276
2277     (SystemStartBracket
2278      . (
2279         (collapse-height . 5.0)
2280         (direction . ,LEFT)
2281         (cross-staff . #t)
2282         (padding . 0.8)
2283         (stencil . ,ly:system-start-delimiter::print)
2284         (style . bracket)
2285         (thickness . 0.45)
2286         (X-offset . ,ly:side-position-interface::x-aligned-side)
2287         (Y-extent . #f)
2288         (meta . ((class . Spanner)
2289                  (interfaces . (font-interface
2290                                 side-position-interface
2291                                 system-start-delimiter-interface))))))
2292
2293     (SystemStartSquare
2294      . (
2295         (direction . ,LEFT)
2296         (cross-staff . #t)
2297         (stencil . ,ly:system-start-delimiter::print)
2298         (style . line-bracket)
2299         (thickness . 1.0)
2300         (X-offset . ,ly:side-position-interface::x-aligned-side)
2301         (Y-extent . #f)
2302         (meta . ((class . Spanner)
2303                  (interfaces . (font-interface
2304                                 side-position-interface
2305                                 system-start-delimiter-interface))))))
2306
2307
2308     (TabNoteHead
2309      . (
2310         (details . ((cautionary-properties . ((angularity . 0.4)
2311                                               (half-thickness . 0.075)
2312                                               (padding . 0)
2313                                               (procedure . ,parenthesize-stencil)
2314                                               (width . 0.25)))
2315                     (head-offset . 3/5)
2316                     (harmonic-properties . ((angularity . 2)
2317                                             (half-thickness . 0.075)
2318                                             (padding . 0)
2319                                             (procedure . ,parenthesize-stencil)
2320                                             (width . 0.25)))
2321                     (repeat-tied-properties . ((note-head-visible . #t)
2322                                                (parenthesize . #t)))
2323                     (tied-properties . ((break-visibility . ,begin-of-line-visible)
2324                                         (parenthesize . #t)))))
2325
2326         (direction . ,CENTER)
2327         (duration-log . ,note-head::calc-duration-log)
2328         (font-series . bold)
2329         (font-size . -2)
2330         (stem-attachment . (0.0 . 1.35))
2331         (stencil . ,tab-note-head::print)
2332         (whiteout . #t)
2333         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
2334         (Y-offset . ,staff-symbol-referencer::callback)
2335         (Y-extent . ,grob::always-Y-extent-from-stencil)
2336         (meta . ((class . Item)
2337                  (interfaces  . (font-interface
2338                                  note-head-interface
2339                                  rhythmic-grob-interface
2340                                  rhythmic-head-interface
2341                                  staff-symbol-referencer-interface
2342                                  tab-note-head-interface
2343                                  text-interface))))))
2344
2345     (TextScript
2346      . (
2347         (avoid-slur . around)
2348         (cross-staff . ,script-or-side-position-cross-staff)
2349         (direction . ,DOWN)
2350         (extra-spacing-width . (+inf.0 . -inf.0))
2351         (outside-staff-horizontal-padding . 0.12)
2352         (outside-staff-priority . 450)
2353
2354         ;; sync with Fingering ?
2355         (padding . 0.3)
2356
2357         (script-priority . 200)
2358         (side-axis . ,Y)
2359         (slur-padding . 0.5)
2360         (staff-padding . 0.5)
2361         (stencil . ,ly:text-interface::print)
2362         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
2363         ;; todo: add X self alignment?
2364         (Y-extent . ,grob::always-Y-extent-from-stencil)
2365         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
2366         (Y-offset . ,side-position-interface::y-aligned-side)
2367         (meta . ((class . Item)
2368                  (interfaces . (font-interface
2369                                 instrument-specific-markup-interface
2370                                 self-alignment-interface
2371                                 side-position-interface
2372                                 text-interface
2373                                 text-script-interface))))))
2374
2375     (TextSpanner
2376      . (
2377         (bound-details . ((left . ((Y . 0)
2378                                    (padding . 0.25)
2379                                    (attach-dir . ,LEFT)
2380                                    ))
2381                           (left-broken . ((attach-dir . ,RIGHT)))
2382                           (right . ((Y . 0)
2383                                     (padding . 0.25)
2384                                     ))
2385                           ))
2386         (dash-fraction . 0.2)
2387         (dash-period . 3.0)
2388         (direction . ,UP)
2389         (font-shape . italic)
2390         (left-bound-info . ,ly:line-spanner::calc-left-bound-info)
2391         (outside-staff-priority . 350)
2392         (right-bound-info . ,ly:line-spanner::calc-right-bound-info)
2393         (side-axis . ,Y)
2394         (staff-padding . 0.8)
2395         (stencil . ,ly:line-spanner::print)
2396         (style . dashed-line)
2397         (Y-offset . ,side-position-interface::y-aligned-side)
2398
2399         (meta . ((class . Spanner)
2400                  (interfaces . (font-interface
2401                                 line-interface
2402                                 line-spanner-interface
2403                                 side-position-interface))))))
2404
2405     (Tie
2406      . (
2407         (avoid-slur . inside)
2408         (control-points . ,ly:tie::calc-control-points)
2409         (details . (
2410                     ;; for a full list, see tie-details.cc
2411                     (ratio . 0.333)
2412                     (center-staff-line-clearance . 0.6)
2413                     (tip-staff-line-clearance . 0.45)
2414                     (note-head-gap . 0.2)
2415                     (stem-gap . 0.35)
2416                     (height-limit . 1.0)
2417                     (horizontal-distance-penalty-factor . 10)
2418                     (same-dir-as-stem-penalty . 8)
2419                     (min-length-penalty-factor . 26)
2420                     (tie-tie-collision-distance . 0.45)
2421                     (tie-tie-collision-penalty . 25.0)
2422                     (intra-space-threshold . 1.25)
2423                     (outer-tie-vertical-distance-symmetry-penalty-factor . 10)
2424                     (outer-tie-length-symmetry-penalty-factor . 10)
2425                     (vertical-distance-penalty-factor . 7)
2426                     (outer-tie-vertical-gap . 0.25)
2427                     (multi-tie-region-size . 3)
2428                     (single-tie-region-size . 4)
2429                     (between-length-limit . 1.0)))
2430
2431         (direction . ,ly:tie::calc-direction)
2432         (font-size . -6)
2433         (line-thickness . 0.8)
2434         (neutral-direction . ,UP)
2435         (springs-and-rods . ,ly:spanner::set-spacing-rods)
2436         (stencil . ,ly:tie::print)
2437         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
2438         (thickness . 1.2)
2439         (meta . ((class . Spanner)
2440                  (interfaces . (tie-interface))))))
2441
2442     (TieColumn
2443      . (
2444         (before-line-breaking . ,ly:tie-column::before-line-breaking)
2445         (positioning-done . ,ly:tie-column::calc-positioning-done)
2446         (X-extent . #f)
2447         (Y-extent . #f)
2448         (meta . ((class . Spanner)
2449                  (interfaces . (tie-column-interface))))))
2450
2451     (TimeSignature
2452      . (
2453         (avoid-slur . inside)
2454         (break-align-anchor
2455          . ,ly:break-aligned-interface::calc-extent-aligned-anchor)
2456         (break-align-symbol . time-signature)
2457         (break-align-anchor-alignment . ,LEFT)
2458         (break-visibility . ,all-visible)
2459         (extra-spacing-height . ,pure-from-neighbor-interface::extra-spacing-height-including-staff)
2460         (extra-spacing-width . (0.0 . 0.8))
2461         (non-musical . #t)
2462         (space-alist . (
2463                         (cue-clef . (extra-space . 1.5))
2464                         (first-note . (fixed-space . 2.0))
2465                         (right-edge . (extra-space . 0.5))
2466                         (staff-bar . (extra-space . 1.0))))
2467         (stencil . ,ly:time-signature::print)
2468         (Y-extent . ,grob::always-Y-extent-from-stencil)
2469         (style . C)
2470         (meta . ((class . Item)
2471                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2472                                       (pure-relevant-grobs . ,ly:pure-from-neighbor-interface::calc-pure-relevant-grobs)))
2473                  (interfaces . (break-aligned-interface
2474                                 font-interface
2475                                 pure-from-neighbor-interface
2476                                 time-signature-interface))))))
2477
2478     (TrillPitchAccidental
2479      . (
2480         (direction . ,LEFT)
2481         (font-size . -4)
2482         (glyph-name-alist . ,standard-alteration-glyph-name-alist)
2483         (padding . 0.2)
2484         (side-axis . ,X)
2485         (stencil . ,ly:accidental-interface::print)
2486         (X-offset . ,ly:side-position-interface::x-aligned-side)
2487         (Y-extent . ,accidental-interface::height)
2488         (meta . ((class . Item)
2489                  (interfaces . (accidental-interface
2490                                 font-interface
2491                                 inline-accidental-interface
2492                                 side-position-interface
2493                                 trill-pitch-accidental-interface))))))
2494
2495     (TrillPitchGroup
2496      . (
2497         (axes . (,X))
2498         (direction . ,RIGHT)
2499         (font-size . -4)
2500         (padding . 0.3)
2501         (side-axis . ,X)
2502         (stencil . ,parenthesize-elements)
2503         (stencils . ,parentheses-item::calc-parenthesis-stencils)
2504         (X-offset . ,ly:side-position-interface::x-aligned-side)
2505         (Y-extent . ,grob::always-Y-extent-from-stencil)
2506         (meta . ((class . Item)
2507                  (interfaces . (axis-group-interface
2508                                 font-interface
2509                                 note-head-interface
2510                                 parentheses-interface
2511                                 side-position-interface))))))
2512
2513     (TrillPitchHead
2514      . (
2515         (duration-log . 2)
2516         (font-size . -4)
2517         (stencil . ,ly:note-head::print)
2518         (Y-offset . ,staff-symbol-referencer::callback)
2519         (Y-extent . ,grob::always-Y-extent-from-stencil)
2520         (meta . ((class . Item)
2521                  (interfaces . (font-interface
2522                                 ledgered-interface
2523                                 pitched-trill-interface
2524                                 rhythmic-head-interface
2525                                 staff-symbol-referencer-interface))))))
2526
2527     (TrillSpanner
2528      . (
2529         (after-line-breaking . ,ly:spanner::kill-zero-spanned-time)
2530         (bound-details . ((left . ((text . ,(make-musicglyph-markup "scripts.trill"))
2531                                    (Y . 0)
2532                                    (stencil-offset . (-0.5 . -1))
2533                                    (padding . 0.5)
2534                                    (attach-dir . ,CENTER)
2535                                    ))
2536                           (left-broken . ((end-on-note . #t)))
2537                           (right . ((Y . 0)))
2538                           ))
2539         (direction . ,UP)
2540         (left-bound-info . ,ly:line-spanner::calc-left-bound-info)
2541         (outside-staff-priority . 50)
2542         (padding . 0.5)
2543         (right-bound-info . ,ly:line-spanner::calc-right-bound-info)
2544         (side-axis . ,Y)
2545         (staff-padding . 1.0)
2546         (stencil . ,ly:line-spanner::print)
2547         (style . trill)
2548         (Y-offset . ,side-position-interface::y-aligned-side)
2549         (meta . ((class . Spanner)
2550                  (interfaces . (font-interface
2551                                 line-interface
2552                                 line-spanner-interface
2553                                 side-position-interface
2554                                 trill-spanner-interface))))))
2555
2556     (TupletBracket
2557      . (
2558         (avoid-scripts . #t)
2559         (connect-to-neighbor . ,ly:tuplet-bracket::calc-connect-to-neighbors)
2560         (cross-staff . ,ly:tuplet-bracket::calc-cross-staff)
2561         (direction  . ,ly:tuplet-bracket::calc-direction)
2562         (edge-height . (0.7 . 0.7))
2563         (full-length-to-extent . #t)
2564         (padding . 1.1)
2565         (positions . ,ly:tuplet-bracket::calc-positions)
2566         (shorten-pair . (-0.2 . -0.2))
2567         (staff-padding . 0.25)
2568         (stencil . ,ly:tuplet-bracket::print)
2569         (thickness . 1.6)
2570         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
2571         (X-positions . ,ly:tuplet-bracket::calc-x-positions)
2572
2573         (meta . ((class . Spanner)
2574                  (interfaces . (line-interface
2575                                 tuplet-bracket-interface))))))
2576
2577     (TupletNumber
2578      . (
2579         (avoid-slur . inside)
2580         (cross-staff . ,ly:tuplet-number::calc-cross-staff)
2581         (direction . ,tuplet-number::calc-direction)
2582         (font-shape . italic)
2583         (font-size . -2)
2584         (stencil . ,ly:tuplet-number::print)
2585         (text . ,tuplet-number::calc-denominator-text)
2586         (X-offset . ,ly:tuplet-number::calc-x-offset)
2587         (Y-offset . ,ly:tuplet-number::calc-y-offset)
2588         (meta . ((class . Spanner)
2589                  (interfaces . (font-interface
2590                                 text-interface
2591                                 tuplet-number-interface))))))
2592
2593
2594     (UnaCordaPedal
2595      . (
2596         (direction . ,RIGHT)
2597         (extra-spacing-width . (+inf.0 . -inf.0))
2598         (font-shape . italic)
2599         (padding . 0.0)  ;; padding relative to UnaCordaPedalLineSpanner
2600         (self-alignment-X . ,CENTER)
2601         (stencil . ,ly:text-interface::print)
2602         (vertical-skylines . ,grob::always-vertical-skylines-from-stencil)
2603         (Y-extent . ,grob::always-Y-extent-from-stencil)
2604         (X-offset . ,ly:self-alignment-interface::x-aligned-on-self)
2605         (meta . ((class . Item)
2606                  (interfaces . (font-interface
2607                                 piano-pedal-script-interface
2608                                 self-alignment-interface
2609                                 text-interface))))))
2610
2611     (UnaCordaPedalLineSpanner
2612      . (
2613         (axes . (,Y))
2614         (cross-staff . ,ly:side-position-interface::calc-cross-staff)
2615         (direction . ,DOWN)
2616         (minimum-space . 1.0)
2617         (outside-staff-priority . 1000)
2618         (padding . 1.2)
2619         (side-axis . ,Y)
2620         (staff-padding . 1.2)
2621         (vertical-skylines . ,grob::always-vertical-skylines-from-element-stencils)
2622         (X-extent . ,ly:axis-group-interface::width)
2623         (Y-extent . ,axis-group-interface::height)
2624         (Y-offset . ,side-position-interface::y-aligned-side)
2625         (meta . ((class . Spanner)
2626                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2627                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
2628                  (interfaces . (axis-group-interface
2629                                 piano-pedal-interface
2630                                 side-position-interface))))))
2631
2632
2633     (VaticanaLigature
2634      . (
2635         (flexa-width . 2.0)
2636         (stencil . ,ly:vaticana-ligature::print)
2637         (thickness . 0.6)
2638         (meta . ((class . Spanner)
2639                  (interfaces . (font-interface
2640                                 vaticana-ligature-interface))))))
2641
2642     (VerticalAlignment
2643      . (
2644         (axes . (,Y))
2645         (positioning-done . ,ly:align-interface::align-to-ideal-distances)
2646         (stacking-dir . -1)
2647         (vertical-skylines . ,ly:axis-group-interface::combine-skylines)
2648         (X-extent . ,ly:axis-group-interface::width)
2649         (Y-extent . ,axis-group-interface::height)
2650         (meta . ((class . Spanner)
2651                  (object-callbacks . ((Y-common . ,ly:axis-group-interface::calc-y-common)
2652                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)
2653                                       (pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)))
2654                  (interfaces . (align-interface
2655                                 axis-group-interface))))))
2656
2657     (VerticalAxisGroup
2658      . (
2659         (adjacent-pure-heights . ,ly:axis-group-interface::adjacent-pure-heights)
2660         (axes . (,Y))
2661         (default-staff-staff-spacing . ((basic-distance . 9)
2662                                         (minimum-distance . 8)
2663                                         (padding . 1)))
2664         (nonstaff-unrelatedstaff-spacing . ((padding . 0.5)))
2665         (outside-staff-placement-directive . left-to-right-polite)
2666         (staff-staff-spacing . ,(ly:make-unpure-pure-container ly:axis-group-interface::calc-staff-staff-spacing ly:axis-group-interface::calc-pure-staff-staff-spacing))
2667         (stencil . ,ly:axis-group-interface::print)
2668         (skyline-horizontal-padding . 0.1)
2669         (vertical-skylines . ,ly:hara-kiri-group-spanner::calc-skylines)
2670         (X-extent . ,ly:axis-group-interface::width)
2671         (Y-extent . ,(ly:make-unpure-pure-container ly:hara-kiri-group-spanner::y-extent ly:hara-kiri-group-spanner::pure-height))
2672         (Y-offset . ,ly:hara-kiri-group-spanner::force-hara-kiri-callback)
2673         (meta . ((class . Spanner)
2674                  (object-callbacks . (
2675                                       (X-common . ,ly:axis-group-interface::calc-x-common)
2676                                       (pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2677                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
2678
2679                  (interfaces . (axis-group-interface
2680                                 hara-kiri-group-spanner-interface))))))
2681
2682     (VoiceFollower
2683      . (
2684         (after-line-breaking . ,ly:spanner::kill-zero-spanned-time)
2685         (bound-details . ((right . ((attach-dir .  ,CENTER)
2686                                     (padding . 1.5)
2687                                       ))
2688                           (left . ((attach-dir .  ,CENTER)
2689                                    (padding . 1.5)
2690                                       ))
2691                           ))
2692         (cross-staff . #t)
2693         (gap . 0.5)
2694         (left-bound-info . ,ly:line-spanner::calc-left-bound-info)
2695         (non-musical . #t)
2696         (right-bound-info . ,ly:line-spanner::calc-right-bound-info)
2697         (stencil . ,ly:line-spanner::print)
2698         (style . line)
2699         (X-extent . #f)
2700         (Y-extent . #f)
2701         (meta . ((class . Spanner)
2702                  (interfaces . (line-interface
2703                                 line-spanner-interface))))))
2704
2705     (VoltaBracket
2706      . (
2707         (direction . ,UP)
2708         (edge-height . (2.0 . 2.0)) ;; staff-space;
2709         (font-encoding . fetaText)
2710         (font-size . -4)
2711         (shorten-pair . ,ly:volta-bracket::calc-shorten-pair)
2712         (stencil . ,ly:volta-bracket-interface::print)
2713         (thickness . 1.6) ;; line-thickness
2714         (word-space . 0.6)
2715         (vertical-skylines . ,grob::unpure-vertical-skylines-from-stencil)
2716         (Y-extent . ,(grob::unpure-Y-extent-from-stencil volta-bracket-interface::pure-height))
2717         (meta . ((class . Spanner)
2718                  (interfaces . (font-interface
2719                                 horizontal-bracket-interface
2720                                 line-interface
2721                                 side-position-interface
2722                                 text-interface
2723                                 volta-bracket-interface
2724                                 volta-interface))))))
2725
2726     (VoltaBracketSpanner
2727      . (
2728         (after-line-breaking . ,ly:side-position-interface::move-to-extremal-staff)
2729         (axes . (,Y))
2730         (direction . ,UP)
2731         (no-alignment . #t)
2732         (outside-staff-priority . 600)
2733         (padding . 1)
2734         (side-axis . ,Y)
2735         (vertical-skylines . ,grob::always-vertical-skylines-from-element-stencils)
2736         (X-extent . ,ly:axis-group-interface::width)
2737         (Y-extent . ,axis-group-interface::height)
2738         (Y-offset . ,side-position-interface::y-aligned-side)
2739         (meta . ((class . Spanner)
2740                  (object-callbacks . ((pure-Y-common . ,ly:axis-group-interface::calc-pure-y-common)
2741                                       (pure-relevant-grobs . ,ly:axis-group-interface::calc-pure-relevant-grobs)))
2742                  (interfaces . (axis-group-interface
2743                                 side-position-interface
2744                                 volta-interface))))))
2745
2746 ))
2747
2748 (define (completize-grob-entry x)
2749   "Transplant assoc key into 'name entry of 'meta of X.  Set interfaces for Item, Spanner etc.
2750 "
2751   ;;  (display (car x))
2752   ;;  (newline)
2753   (let* ((name-sym  (car x))
2754          (grob-entry (cdr x))
2755          (meta-entry (assoc-get 'meta grob-entry))
2756          (class (assoc-get 'class meta-entry))
2757          (ifaces-entry
2758           (assoc-get 'interfaces meta-entry)))
2759
2760     (cond
2761      ((eq? 'Item class)
2762       (set! ifaces-entry (cons 'item-interface ifaces-entry)))
2763      ((eq? 'Spanner class)
2764       (set! ifaces-entry (cons 'spanner-interface ifaces-entry)))
2765      ((eq? 'Paper_column class)
2766       (set! ifaces-entry (cons 'item-interface
2767                                (cons 'paper-column-interface ifaces-entry))))
2768      ((eq? 'System class)
2769       (set! ifaces-entry (cons 'system-interface
2770                                (cons 'spanner-interface ifaces-entry))))
2771      (else
2772       (ly:warning "Unknown class ~a" class)))
2773
2774     (set! ifaces-entry (uniq-list (sort ifaces-entry symbol<?)))
2775     (set! ifaces-entry (cons 'grob-interface ifaces-entry))
2776
2777     (set! meta-entry (assoc-set! meta-entry 'name name-sym))
2778     (set! meta-entry (assoc-set! meta-entry 'interfaces
2779                                  ifaces-entry))
2780     (set! grob-entry (assoc-set! grob-entry 'meta meta-entry))
2781     (cons name-sym grob-entry)))
2782
2783 (set! all-grob-descriptions (map completize-grob-entry all-grob-descriptions))
2784
2785 ;;  (display (map pair? all-grob-descriptions))
2786
2787 ;; make sure that \property Foo.Bar =\turnOff doesn't complain
2788
2789 (map (lambda (x)
2790        ;; (display (car x)) (newline)
2791
2792        (set-object-property! (car x) 'translation-type? list?)
2793        (set-object-property! (car x) 'is-grob? #t))
2794      all-grob-descriptions)
2795
2796 (set! all-grob-descriptions (sort all-grob-descriptions alist<?))