]> git.donarmstrong.com Git - lilypond.git/blob - scm/grob-description.scm
6f72730b9b857264aa0ccb251e9eb28ba87156ec
[lilypond.git] / scm / grob-description.scm
1 ;;;; grob-description.scm -- part of generated backend documentation
2 ;;;;
3 ;;;;  source file of the GNU LilyPond music typesetter
4 ;;;; 
5 ;;;; (c) 1998--20.301  Han-Wen Nienhuys <hanwen@cs.uu.nl>
6 ;;;;                 Jan Nieuwenhuizen <janneke@gnu.org>
7
8 ;;;; distances are given in stafflinethickness (thicknesses) and
9 ;;;; staffspace (distances)
10
11 ;;;; WARNING: the meta field should be the last one.
12
13 ;; TODO: junk the meta field in favor of something more compact?
14 (define all-grob-descriptions
15   `(
16     (Accidental
17      . (
18         (molecule-callback . ,Accidental_interface::brew_molecule)
19         (font-family . music)
20         (cautionary-style . smaller)
21         (after-line-breaking-callback . ,Accidental_interface::after_line_breaking)             (meta . ((interfaces . (item-interface accidental-interface font-interface))))
22         ))
23     (AccidentalPlacement
24      . (
25         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
26         (left-padding . 0.3)
27
28         ;; this is quite small, but it is very ugly to have
29         ;; accs closer to the previous note than to the next one.
30         (right-padding . 0.15)
31         (meta . ((interfaces . (item-interface accidental-placement-interface))))
32         ))
33
34     (Ambitus
35      . (
36        (breakable . #t)
37        (break-align-symbol . ambitus)
38        (molecule-callback . ,Ambitus::brew_molecule)
39        (font-family . music)
40        (note-head-style . "noteheads-2")
41        (visibility-lambda . ,begin-of-line-visible)
42        (join-heads . #t)
43        (space-alist . (
44                        (clef . (extra-space . 0.0))
45                        (key-signature . (extra-space . 0.0))
46                        (staff-bar . (extra-space . 0.0))
47                        (time-signature . (extra-space . 0.0)) 
48                        (first-note . (extra-space . 0.0))
49                        ))
50        (meta . ((interfaces . (ambitus-interface staff-symbol-referencer-interface break-aligned-interface item-interface  font-interface))))
51        ))
52
53     (Arpeggio
54      . (
55         (X-extent-callback . ,Arpeggio::width_callback)
56         (Y-extent-callback . #f)               
57         (molecule-callback . ,Arpeggio::brew_molecule)
58         (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
59         (X-offset-callbacks . (,Side_position_interface::aligned_side))
60         (direction . -1)
61         (staff-position . 0.0)
62         (meta . ((interfaces . (arpeggio-interface staff-symbol-referencer-interface side-position-interface item-interface font-interface))))
63         ))
64
65     (BarLine
66      . (
67         (break-align-symbol . staff-bar)
68         (glyph . "|")
69         (break-glyph-function . ,default-break-barline)
70         (bar-size-procedure . ,Bar_line::get_staff_bar_size)
71         (molecule-callback . ,Bar_line::brew_molecule)     
72         (break-visibility . ,all-visible)
73         (breakable . #t)
74         (before-line-breaking-callback . ,Bar_line::before_line_breaking)
75         (space-alist . (
76                         (time-signature . (extra-space . 0.75)) 
77                         (custos . (minimum-space . 2.0))
78                         (clef .   (minimum-space . 1.0))
79                         (first-note . (extra-space . 1.3))
80                         ))
81
82         ;;
83         ;; Ross. page 151 lists other values, we opt for a leaner look
84         ;; 
85         (kern . 3.0)
86         (thin-kern . 3.0)
87         (hair-thickness . 1.6)
88         (thick-thickness . 6.0)
89         (meta . ((interfaces . (bar-line-interface item-interface   break-aligned-interface font-interface))))
90         ))
91
92     
93     (BarNumber
94      . (
95         (molecule-callback . ,Text_item::brew_molecule)
96         (breakable . #t)
97         (break-visibility . ,begin-of-line-visible)
98         (padding . 1.0)
99         (direction . 1)
100         (font-family . roman)
101         (font-relative-size . -1)
102         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
103         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
104         (self-alignment-X . 1)
105         (extra-offset . (1.3 . 0))
106         (meta .
107               ((interfaces . (side-position-interface
108                               text-interface
109                               self-alignment-interface
110                               font-interface item-interface  break-aligned-interface))))
111
112              ))
113
114     (BassFigure
115      . (
116         (molecule-callback . ,brew-bass-figure)
117         (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
118         (direction . 0)
119         (font-family . number)
120         (font-relative-size . -1)
121         (padding . 0.1)
122         (kern . 0.2)
123         (thickness . 1.0)
124         (meta . ((interfaces . (text-interface bass-figure-interface item-interface self-alignment-interface font-interface))))
125         ))
126     (Beam
127      . (
128         ;; todo: clean this up a bit: the list is getting
129         ;; rather long.
130         (molecule-callback . ,Beam::brew_molecule)
131         (concaveness-gap . 2.0)
132         (concaveness-threshold . 0.08)
133         (positions . (#f . #f))
134         (position-callbacks . (,Beam::least_squares
135                                ,Beam::check_concave
136                                ,Beam::slope_damping
137                                ,Beam::shift_region_to_valid
138                                ,Beam::quanting
139                               ))
140
141         ;; TODO: should be in SLT.
142         (thickness . 0.48) ; in staff-space
143         (before-line-breaking-callback . ,Beam::before_line_breaking)
144         (after-line-breaking-callback . ,Beam::after_line_breaking)
145         (neutral-direction . -1)
146         (dir-function . ,beam-dir-majority-median)
147         
148         ;; Whe have some unreferenced problems here.
149         ;;
150         ;; If we shorten beamed stems less than normal stems (1 staffspace),
151         ;; or high order less than 8th beams, patterns like
152         ;;     c''4 [c''8 c''] c''4 [c''16 c]
153         ;; are ugly (different stem lengths).
154         ;;
155         ;; But if we shorten 16th beams as much as 8th beams, a single
156         ;; forced 16th beam looks *very* short.
157
158         ;; We choose to shorten 8th beams the same as single stems,
159         ;; and high order beams less than 8th beams, so that all
160         ;; isolated shortened beams look nice and a bit shortened,
161         ;; sadly possibly breaking patterns with high order beams.
162         (beamed-stem-shorten . (1.0 0.5 0.25))
163         
164         (outer-stem-length-limit . 0.2)
165         (slope-limit . 0.2)
166         (flag-width-function . ,default-beam-flag-width-function)
167         (damping . 1)
168         (auto-knee-gap . 5.5)
169         (font-name . "cmr10")
170         (space-function . ,Beam::space_function)
171         (meta . ((interfaces . (staff-symbol-referencer-interface beam-interface spanner-interface))))
172         ))
173
174     (BreakAlignment
175      . (
176         (breakable . #t)
177         (stacking-dir . 1)
178         (axes . (0))
179         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
180         (meta . ((interfaces . (break-alignment-interface item-interface axis-group-interface)))))
181         )
182
183     (BreakAlignGroup
184      . (
185         (axes  . (0))
186         (X-offset-callbacks . (,Break_align_interface::alignment_callback))
187         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
188         (meta . ((interfaces . (break-aligned-interface item-interface axis-group-interface item-interface ))))
189         ))
190
191     (BreathingSign
192      . (
193         (break-align-symbol . breathing-sign)
194         (breakable . #t)
195         (space-alist . (
196                         (ambitus . (extra-space . 2.0))
197                         (key-signature . (minimum-space . 1.5))
198                         (staff-bar . (minimum-space . 1.5))
199                         (clef . (minimum-space . 2.0))
200                         (first-note . (minimum-space . 1.0))
201                         ))
202         (molecule-callback . ,Text_item::brew_molecule)
203         (lookup . name)
204         (font-family . music)
205         (text . "scripts-rcomma")
206         (Y-offset-callbacks . (,Breathing_sign::offset_callback))
207         (break-visibility . ,begin-of-line-invisible)
208         (meta . ((interfaces . (break-aligned-interface breathing-sign-interface text-interface font-interface item-interface ))))
209         ))
210
211     (Clef
212      . (
213         (molecule-callback . ,Clef::brew_molecule)
214         (before-line-breaking-callback . ,Clef::before_line_breaking)
215         (breakable . #t)
216         (font-family . music)      
217         (break-align-symbol . clef)
218         (break-visibility . ,begin-of-line-visible)
219         (space-alist . (
220                         (ambitus . (extra-space . 2.0))
221                         (staff-bar . (minimum-space .  3.7))
222                         (key-signature . (minimum-space . 4.0))
223                         (time-signature . (minimum-space . 4.2))
224                         (first-note . (minimum-space . 5.0))
225                         (next-note . (extra-space . 0.5))                       
226                         ))
227         (Y-offset-callbacks  . (,Staff_symbol_referencer::callback)) 
228         (meta . ((interfaces . (clef-interface staff-symbol-referencer-interface font-interface break-aligned-interface item-interface ))))
229         ))
230
231     (ChordName
232      . (
233         (molecule-callback . ,Chord_name::brew_molecule)
234         (after-line-breaking-callback . ,Chord_name::after_line_breaking)
235         (chord-name-function . ,default-chord-name-function)
236         (font-family . roman)
237         (meta . ((interfaces . (font-interface text-interface chord-name-interface item-interface ))))
238         ))
239
240     (Custos
241      . (
242         (break-align-symbol . custos)
243         (breakable . #t)
244         (molecule-callback . ,Custos::brew_molecule)
245         (break-visibility . ,end-of-line-visible)
246         (style . vaticana)
247         (neutral-position . 0)
248         (neutral-direction . -1)
249         (adjust-if-on-staffline . #t)
250         (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
251         (font-family . ancient)
252         (space-alist . (
253                         (first-note . (minimum-space . 0.0))
254                         ))
255         (meta . ((interfaces
256                   . (custos-interface staff-symbol-referencer-interface
257                                       font-interface
258                                       break-aligned-interface item-interface ))))
259         ))
260
261
262     (DotColumn
263      . (
264         (axes . (0))
265         (direction . 1)
266         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
267         (X-offset-callbacks . (,Dot_column::side_position))
268         (meta . ((interfaces . (dot-column-interface axis-group-interface item-interface ))))
269         ))
270
271     (Dots
272      . (
273         (molecule-callback . ,Dots::brew_molecule)
274         (dot-count . 1)
275         (Y-offset-callbacks  . (,Dots::quantised_position_callback ,Staff_symbol_referencer::callback))
276         (meta . ((interfaces . (font-interface staff-symbol-referencer-interface dots-interface item-interface ))))
277         ))
278
279     (DoublePercentRepeat .
280                          (
281                           (molecule-callback . ,Percent_repeat_item_interface::double_percent)
282                           (breakable . #t)
283                           (slope . 1.0)
284                           (font-family . music)
285                           (width . 2.0)
286                           (thickness . 0.48)
287                           (break-align-symbol . staff-bar)
288                           (break-visibility . ,begin-of-line-invisible)
289                           (meta . ((interfaces . (font-interface
290                                                   break-aligned-interface
291                                                   percent-repeat-interface item-interface ))))
292                          ))
293
294     (DynamicText
295      . (
296         (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
297         (molecule-callback . ,Text_item::brew_molecule)
298         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self
299                                ,Self_alignment_interface::centered_on_parent))
300         (self-alignment-X . 0)
301         (no-spacing-rods . #t)
302         (script-priority . 100)
303         (font-series . bold)
304         (font-family . dynamic)
305         (font-shape . italic)
306         (self-alignment-Y . 0)
307         (meta . ((interfaces . (font-interface text-interface self-alignment-interface  dynamic-interface script-interface item-interface ))))
308         ))
309
310     (DynamicLineSpanner
311      . (
312         (axes . (1))
313         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
314         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
315         (padding . 0.6)
316         (minimum-space . 1.2)
317         (direction . -1)
318         (meta . ((interfaces . (dynamic-interface axis-group-interface side-position-interface spanner-interface))))
319         ))
320
321     (LeftEdge
322      . (
323         (break-align-symbol . left-edge)
324         (X-offset-callbacks . (,Break_align_interface::alignment_callback))
325         (X-extent-callback . ,Grob::point_dimension_callback)
326         (breakable . #t)
327         (space-alist . (
328                         (custos . (extra-space . 0.0))
329                         (ambitus . (extra-space . 2.0))
330                         (time-signature . (extra-space . 0.0)) 
331                         (staff-bar . (extra-space . 0.0))
332                         (breathing-sign . (minimum-space  . 0.0))
333                         (clef . (extra-space . 1.0))
334                         (first-note . (extra-space . 0.0))
335                         (key-signature . (extra-space . 0.0))
336                         ))
337         (meta . ((interfaces . (break-aligned-interface item-interface ))))
338         ))
339
340     (Fingering
341      . (
342         (molecule-callback . ,Text_item::brew_molecule)
343         (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent
344                                ,Self_alignment_interface::aligned_on_self))
345         (padding . 0.6)
346         ;;              (direction . -1)
347         (self-alignment-X . 0)
348         (self-alignment-Y . 0)
349         (script-priority . 100)
350         (font-family . number)
351         (font-relative-size . -3)
352         (font-shape . upright)
353         (meta . ((interfaces . (finger-interface font-interface text-script-interface text-interface side-position-interface self-alignment-interface item-interface ))))
354         ))
355
356
357     (HaraKiriVerticalGroup
358      . (
359         (Y-offset-callbacks . (,Hara_kiri_group_spanner::force_hara_kiri_callback))
360         (Y-extent-callback . ,Hara_kiri_group_spanner::y_extent)
361         (axes . (1))
362         (meta . ((interfaces . (axis-group-interface hara-kiri-group-interface item-interface  spanner-interface))))
363         ))
364
365     (Hairpin
366      . (
367         (molecule-callback . ,Hairpin::brew_molecule)
368         (thickness . 1.0)
369         (height . 0.6666)
370         (spacing-procedure . ,Spanner::set_spacing_rods)
371         (minimum-length . 2.0)
372         (if-text-padding . 1.0)
373         (width-correct . -1.0)
374
375         (dash-thickness . 1.2)
376         (dash-length . 4.0)
377         (self-alignment-Y . 0)
378         (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
379         (meta . ((interfaces . (hairpin-interface self-alignment-interface dynamic-interface spanner-interface))))
380         ))
381
382     (InstrumentName
383      . (
384         (breakable . #t)
385         (Y-offset-callbacks . (,Self_alignment_interface::aligned_on_self
386                                ,Side_position_interface::aligned_on_support_refpoints))
387         ;; huh? what's this for?
388         (direction . 0)
389         (space-alist . (
390                         (left-edge . (extra-space . 1.0))
391                         ))
392
393         (self-alignment-Y . 0)
394         (molecule-callback . ,Text_item::brew_molecule)         
395         (break-align-symbol . instrument-name)
396         (break-visibility . ,begin-of-line-visible)
397         (baseline-skip . 2)
398         (font-family . roman)
399         (meta . ((interfaces . (font-interface self-alignment-interface side-position-interface text-interface break-aligned-interface item-interface ))))
400         ))
401
402     (KeySignature
403      . (
404         (molecule-callback . ,Key_signature_interface::brew_molecule)
405         (space-alist . (
406                         (time-signature . (extra-space . 1.25))
407                         (staff-bar .  (extra-space . 1.1))
408                         (first-note . (extra-space . 2.5))
409                         ))
410         (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
411         (break-align-symbol . key-signature)
412         (break-visibility . ,begin-of-line-visible)
413         (breakable . #t)
414         (meta . ((interfaces . (key-signature-interface  font-interface  break-aligned-interface item-interface ))))
415         ))
416
417     (Ligature
418      . (
419         (molecule-callback . ,Ligature_bracket::brew_molecule)
420         (meta . ((interfaces . (ligature-interface))))
421         ))
422
423     (LigatureBracket
424      . (
425         (width . 0.75)
426         (height . 0.5)
427         (ligature-primitive-callback . ,Note_head::brew_molecule)
428         (molecule-callback . ,Ligature_bracket::brew_molecule)
429         (meta . ((interfaces . (ligature-bracket-interface spanner-interface))))
430         ))
431
432     (LigatureHead
433      . (
434         (ligature-primitive-callback . ,Note_head::brew_molecule)
435         (molecule-callback . ,Ligature_head::brew_molecule)
436         (Y-offset-callbacks  . (,Staff_symbol_referencer::callback))
437         (stem-attachment-function . ,note-head-style->attachment-coordinates)
438         (font-family . ancient)
439         (style . mensural)
440         (meta . ((interfaces . (ligature-head-interface rhythmic-head-interface
441                                                         font-interface
442                                                         note-head-interface staff-symbol-referencer-interface))))
443         ))
444
445     (LyricHyphen
446      . (
447         (thickness . 1.0)
448         (height . 0.4)
449         (minimum-length .  0.5) 
450         (maximum-length .  100)
451         (molecule-callback . ,Hyphen_spanner::brew_molecule)
452         (Y-extent-callback . ,Grob::point_dimension_callback)
453         (meta . ((interfaces . (lyric-hyphen-interface spanner-interface))))
454         ))
455
456     (LyricExtender
457      . (
458         (molecule-callback . ,Lyric_extender::brew_molecule)
459         (height . 0.8) ; stafflinethickness;
460         (right-trim-amount . 0.5)
461         (Y-extent-callback . ,Grob::point_dimension_callback)
462         (meta . ((interfaces . (lyric-extender-interface spanner-interface))))
463         ))
464
465     (LyricText
466      . (
467         (molecule-callback . ,Text_item::brew_molecule)
468         (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent
469                                ,Self_alignment_interface::aligned_on_self))
470         (self-alignment-X . 0)
471         (word-space . 0.6)
472         (ignore-length-mismatch . #f)
473         (begin-alignment . 4)
474         (end-alignment . 2)
475         (font-family . roman)
476         (font-shape . upright)
477         
478         ;; duh, side-position-interface?
479         (meta . ((interfaces . (lyric-syllable-interface self-alignment-interface text-interface font-interface item-interface ))))
480         ))
481
482     (MensuralLigature
483      . (
484         (thickness . 1.4)
485         (flexa-width . 2.0)
486         (ligature-primitive-callback . ,Mensural_ligature::brew_ligature_primitive)
487         (molecule-callback . ,Mensural_ligature::brew_molecule)
488         (font-family . ancient)
489         (meta . ((interfaces . (mensural-ligature-interface font-interface))))
490         ))
491
492     (Porrectus
493      . (
494         (style . mensural)
495         (auto-properties . #f)
496         (solid . #f)
497         (width . 2.4)
498         (thickness . 1.0)
499         (add-stem . #t)
500         (direction . 1)
501         (molecule-callback . ,Porrectus::brew_molecule)
502         (meta . ((interfaces . (porrectus-interface))))
503         ))
504
505     (RehearsalMark
506      . (
507         (molecule-callback . ,Text_item::brew_molecule)
508         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
509         (Y-offset-callbacks . (,Side_position_interface::aligned_side)) 
510         (self-alignment-X . 0)
511
512         (direction . 1)
513         (breakable . #t)
514         (font-family . roman)
515         (baseline-skip . 2)
516         (break-visibility . ,end-of-line-invisible)
517         (padding . 0.8)
518         (meta . ((interfaces . (text-interface side-position-interface font-interface mark-interface self-alignment-interface item-interface ))))
519         ))
520
521     (MultiMeasureRest
522      . (
523         (spacing-procedure . ,Multi_measure_rest::set_spacing_rods)
524         (molecule-callback . ,Multi_measure_rest::brew_molecule)
525         (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
526         (staff-position . 0)
527         (expand-limit . 10)
528         (number-threshold . 1)
529         (padding . 1)
530         (thickness . 6.6)
531         (font-family . number)
532         (padding . 1)
533         (meta . ((interfaces . (multi-measure-rest-interface rest-interface font-interface staff-symbol-referencer-interface spanner-interface))))
534         ))
535
536     (NoteCollision
537      . (
538         (axes . (0 1))
539         ;; Ugh, should not be hard-coded. 
540         (note-width . 1.321)
541         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
542         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
543         (meta . ((interfaces . (note-collision-interface axis-group-interface item-interface ))))
544         ))
545
546     (NoteColumn
547      . (
548         (axes . (0 1))
549         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
550         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
551         (meta . ((interfaces . (axis-group-interface note-column-interface item-interface ))))
552         ))
553
554     (NoteHead
555      . (
556         (style . default)
557         (molecule-callback . ,Note_head::brew_molecule)
558         (Y-offset-callbacks  . (,Staff_symbol_referencer::callback))
559         (stem-attachment-function . ,note-head-style->attachment-coordinates)
560         (meta . ((interfaces . (rhythmic-head-interface font-interface note-head-interface staff-symbol-referencer-interface item-interface ))))
561         ))
562
563     (Glissando
564      . (
565         (type . line)
566         (gap . 0.5)
567         (breakable . #t)
568         (X-extent-callback . #f)
569         (Y-extent-callback . #f)                         
570         (molecule-callback . ,Line_spanner::brew_molecule)
571         (meta . ((interfaces . (line-spanner-interface spanner-interface))))
572         ))
573
574     (VoiceFollower
575      . (
576         (type . line)
577         (gap . 0.5)
578         (breakable . #t)
579         (X-extent-callback . #f)
580         (Y-extent-callback . #f)                         
581         (molecule-callback . ,Line_spanner::brew_molecule)
582         (meta . ((interfaces . (line-spanner-interface spanner-interface))))
583         ))
584
585     (NoteName
586      . (
587         (molecule-callback . ,Text_item::brew_molecule)
588         (font-family . roman)
589         (meta . ((interfaces . (note-name-interface text-interface font-interface item-interface ))))
590         ))
591
592     (OctavateEight
593      . (
594         (self-alignment-X . 0)
595         (text . "8")
596         (break-visibility . ,begin-of-line-visible)
597         (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent ,Self_alignment_interface::aligned_on_self))
598         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
599         (molecule-callback . ,Text_item::brew_molecule)
600         (font-shape . italic)
601         (padding . 0.4)
602         (font-relative-size . -2)
603         (font-family . roman)
604         (meta . ((interfaces . (text-interface self-alignment-interface side-position-interface font-interface item-interface ))))
605         ))
606
607     (PaperColumn
608      . (
609         (axes . (0))
610         (before-line-breaking-callback . ,Paper_column::before_line_breaking)
611         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
612
613 ;               (molecule-callback . ,Paper_column::brew_molecule) (font-name . "cmr8") (Y-extent-callback . #f)
614         (meta . ((interfaces . (paper-column-interface axis-group-interface spaceable-grob-interface item-interface ))))
615         ))
616
617     (PhrasingSlur
618      . (
619         (molecule-callback . ,Slur::brew_molecule)
620         (thickness . 1.2)               
621         (spacing-procedure . ,Spanner::set_spacing_rods)                
622         (minimum-length . 1.5)
623         (after-line-breaking-callback . ,Slur::after_line_breaking)
624         (extremity-rules . ,default-slur-extremity-rules)
625         (extremity-offset-alist . ,default-phrasing-slur-extremity-offset-alist)
626         (de-uglify-parameters . (1.5  0.8  -2.0))
627         (Y-extent-callback . ,Slur::height)
628         (height-limit . 2.0)
629         (ratio . 0.333)
630         (beautiful . 0.5)
631         (y-free . 0.75)
632         (attachment . (#f . #f))
633         (attachment-offset . ((0 . 0) . (0 . 0)))
634         (slope-limit . 0.8)
635         (details . ((force-blowfit . 0.5)
636                     (bezier-pct-c0 . -0.2) (bezier-pct-c3 . 0.000006)
637                     (bezier-pct-out-max . 0.8) (bezier-pct-in-max . 1.2)
638                     (bezier-area-steps . 1.0)))
639         (meta . ((interfaces . (slur-interface spanner-interface))))
640         ))
641
642     (NonMusicalPaperColumn
643      . (
644         (axes . (0))
645         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
646         (before-line-breaking-callback . ,Paper_column::before_line_breaking)
647         ;; debugging stuff: print column number.
648 ;       (molecule-callback . ,Paper_column::brew_molecule) (font-name . "cmr8") (Y-extent-callback . #f)
649
650
651         (meta .  ((interfaces . (paper-column-interface axis-group-interface spaceable-grob-interface item-interface ))))
652         ))
653
654     (PercentRepeat
655      . (
656         (spacing-procedure . ,Multi_measure_rest::set_spacing_rods)
657         (molecule-callback . ,Multi_measure_rest::percent)
658         (slope . 1.0)
659         (thickness . 0.48)
660         (minimum-width . 12.5) ; staffspace
661         (font-family . music)
662         (meta . ((interfaces . (multi-measure-rest-interface  spanner-interface font-interface percent-repeat-interface))))
663         ))
664
665     (PianoPedalBracket   ;; an example of a text spanner
666      . (
667         (molecule-callback . ,Text_spanner::brew_molecule)
668         (font-family . roman)
669         (type . line)
670         (if-text-padding . 1.0)
671         (width-correct . 0)
672         (outer . #t)
673         (direction . -1)
674         (edge-widen . (0.5 . 0.5))
675         (edge-height . (1.0 . 1.0))
676         (shorten-pair . (0.0 . 0.0))
677         (thickness .  1.0)
678         (meta . ((interfaces . (text-spanner-interface piano-pedal-interface spanner-interface))))
679         ))
680
681     (RepeatSlash
682      . (
683         (molecule-callback . , Percent_repeat_item_interface::beat_slash)
684         (thickness . 0.48)
685         (slope . 1.7)
686         (meta . ((interfaces . (percent-repeat-interface item-interface ))))
687         ))
688     (Rest
689      . (
690         (after-line-breaking-callback . ,Rest::after_line_breaking)
691         (X-extent-callback . ,Rest::extent_callback)
692         (Y-extent-callback . ,Rest::extent_callback)            
693         (molecule-callback . ,Rest::brew_molecule)
694         (Y-offset-callbacks . (,Staff_symbol_referencer::callback)) 
695         (minimum-beam-collision-distance . 1.5)
696         (meta . (
697                  (interfaces . (font-interface
698                                 rhythmic-head-interface
699                                 staff-symbol-referencer-interface
700                                 rest-interface item-interface ))
701                 ))))
702
703     (RestCollision
704      . (
705         (minimum-distance . 0.75)
706         (meta . ((interfaces . (rest-collision-interface item-interface ))))
707         ))
708
709     (Script
710      . (
711         ;; don't set direction here: it breaks staccato.
712         (molecule-callback . ,Script_interface::brew_molecule)
713
714         ;; This value is sensitive: if too large, staccato dots will move a
715         ;; space a away.
716         (padding . 0.25)
717         ;; (script-priority . 0) priorities for scripts, see script.scm
718         (X-offset-callbacks . (,Self_alignment_interface::centered_on_parent))
719         (before-line-breaking-callback . ,Script_interface::before_line_breaking)
720         (font-family . music)
721         (meta . ((interfaces . (script-interface side-position-interface font-interface item-interface ))))
722         ))
723
724     (ScriptColumn
725      . (
726         (before-line-breaking-callback . ,Script_column::before_line_breaking)
727         (meta . ((interfaces . (script-column-interface item-interface ))))
728         ))
729
730     (Slur
731      . (
732         (molecule-callback . ,Slur::brew_molecule)
733         (thickness . 1.2)               
734         (spacing-procedure . ,Spanner::set_spacing_rods)                
735         (minimum-length . 1.5)
736         (after-line-breaking-callback . ,Slur::after_line_breaking)
737         (extremity-rules . ,default-slur-extremity-rules)
738         (extremity-offset-alist . ,default-slur-extremity-offset-alist)
739         (de-uglify-parameters . (1.5  0.8  -2.0))
740         (Y-extent-callback . ,Slur::height)
741         (height-limit . 2.0)
742         (ratio . 0.333)
743         (beautiful . 0.5)
744         (y-free . 0.75)
745         (attachment . (#f . #f))
746         (attachment-offset . ((0 . 0) . (0 . 0)))
747         (slope-limit . 0.8)
748         (details . ((force-blowfit . 0.5)
749                     (bezier-pct-c0 . -0.2) (bezier-pct-c3 . 0.000006)
750                     (bezier-pct-out-max . 0.8) (bezier-pct-in-max . 1.2)
751                     (bezier-area-steps . 1.0)))
752         (meta . ((interfaces . (slur-interface spanner-interface))))
753         ))
754
755     (SpacingSpanner
756      . (
757         (spacing-procedure .  ,Spacing_spanner::set_springs)
758         (grace-space-factor . 0.6)
759         (shortest-duration-space . 2.0)
760         (spacing-increment . 1.2)
761         (base-shortest-duration . ,(make-moment 1 8))
762         (meta . ((interfaces . (spacing-interface spacing-spanner-interface spanner-interface))))
763         ))
764
765     (SpanBar
766      . (
767         (break-align-symbol . staff-bar)
768         (bar-size-procedure . ,Span_bar::get_bar_size) 
769         (molecule-callback . ,Span_bar::brew_molecule)
770         (break-visibility . ,begin-of-line-invisible)
771         (X-extent-callback . ,Span_bar::width_callback)
772         (Y-extent-callback . ())
773         (breakable . #t)
774         (glyph . "|")
775         (before-line-breaking-callback . ,Span_bar::before_line_breaking)
776         ;; ugh duplication! 
777
778         ;;
779         ;; Ross. page 151 lists other values, we opt for a leaner look
780         ;; 
781         (kern . 3.0)
782         (thin-kern . 3.0)
783         (hair-thickness . 1.6)
784         (thick-thickness . 6.0)
785         (meta . ((interfaces . (span-bar-interface font-interface
786                                                    bar-line-interface item-interface ))))
787         ))
788
789     (StanzaNumber
790      . (
791         (breakable . #t)
792         (molecule-callback . ,Text_item::brew_molecule)         
793         (break-align-symbol . clef)
794         (break-visibility . ,begin-of-line-visible)
795         (font-family . roman)
796         (meta . ((interfaces . (break-aligned-interface text-interface font-interface item-interface ))))               
797         ))
798
799     (StaffSpacing
800      . (
801         (breakable . #t)
802         (stem-spacing-correction . 0.4)
803         (knee-spacing-correction . 0.75)
804         (meta . ((interfaces . (spacing-interface staff-spacing-interface item-interface ))))
805         ))
806     (NoteSpacing
807      . (
808         (stem-spacing-correction . 0.5)
809         (knee-spacing-correction . 0.75)
810         (meta . ((interfaces . (spacing-interface note-spacing-interface item-interface ))))
811         ))
812
813     (StaffSymbol
814      . (
815         (molecule-callback . ,Staff_symbol::brew_molecule)
816         (line-count . 5)
817         (layer . 0)
818         (meta . ((interfaces . (staff-symbol-interface spanner-interface))))
819         ))
820
821     (SostenutoPedal
822      . (
823         (molecule-callback . ,Text_item::brew_molecule)
824         (direction . 1)
825         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
826         (no-spacing-rods . #t)
827         (padding . 0.0) ;; padding relative to SostenutoPedalLineSpanner
828         (pedal-type . mixed)
829         (font-family . roman)
830         (font-shape . italic)
831         (self-alignment-X . 0)
832         (meta . ((interfaces . (text-interface  self-alignment-interface font-interface item-interface))))
833         ))
834
835     (SostenutoPedalLineSpanner 
836      . (
837         (axes . (1))
838         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
839         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
840         
841
842         (padding . 1.2)
843         (minimum-space . 1.0)
844         (direction . -1)
845         (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface  spanner-interface))))
846         ))
847         
848     (Stem
849      . (
850         (before-line-breaking-callback . ,Stem::before_line_breaking)
851         (molecule-callback . ,Stem::brew_molecule)
852         (thickness . 1.3)
853
854         ;; 3.5 (or 3 measured from note head) is standar length
855         ;; 32nd, 64th flagged stems should be longer
856         (lengths . (3.5 3.5 3.5 4.5 5.0))
857         
858         ;; Stems in unnatural (forced) direction should be shortened by
859         ;; one staff space, according to [Roush & Gourlay].
860         ;; Flagged stems we shorten only half a staff space.
861         (stem-shorten . (1.0 0.5))
862
863         ;; default stem direction for note on middle line
864         (neutral-direction . -1)
865         
866         ;; [Wanske]: standard length (but no shorter than minimum).
867         ;; (beamed-lengths . (3.5))
868         
869         ;; FIXME.  3.5 yields too long beams (according to Ross and
870         ;; looking at Baerenreiter examples) for a number of common
871         ;; boundary cases.  Subtracting half a beam thickness fixes
872         ;; this, but the bug may well be somewhere else.
873         (beamed-lengths . (3.26))
874
875         ;; [Wanske] lists three sets of minimum lengths.  One
876         ;; set for the nomal case, and one set for beams with `der
877         ;; Balkenendpunkt weiter "uber bzw. unter die Systemgrenze
878         ;; hinaus (bei Gruppen mit grossem Tonumfang)' and the extreme
879         ;; case.
880
881         ;; Note that Wanske lists numbers lengths starting from top of
882         ;; head, so we must add half a staff space.
883         
884         ;; We use the normal minima as minimum for the ideal lengths,
885         ;; and the extreme minima as abolute minimum length.
886         
887         ;; The 'normal' minima
888         (beamed-minimum-free-lengths . (2.5 2.0 1.5))
889         
890         ;; The 'far outside staff' minima, not used
891         ;(beamed-far-minimum-free-lengths . (1.83))
892         
893         ;; The 'extreme case' minima
894         (beamed-extreme-minimum-free-lengths . (1.83 1.5))
895
896         (X-offset-callbacks . (,Stem::off_callback))
897         (X-extent-callback . ,Stem::dim_callback)       
898         (Y-extent-callback . ,Stem::height)
899         (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
900         (adjust-if-on-staffline . #t)
901         (font-family . music)      
902         (avoid-note-head . #f)
903         (up-to-staff . #f)
904         (meta . ((interfaces . (stem-interface  font-interface item-interface ))))
905         ))
906
907     (StemTremolo
908      . (
909         (molecule-callback . ,Stem_tremolo::brew_molecule)
910         (Y-extent-callback . ,Stem_tremolo::height)
911         (X-extent-callback . #f)
912
913         (beam-width . 1.6) ; staff-space
914         (beam-thickness . 0.48) ; staff-space
915         (meta . ((interfaces . (stem-tremolo-interface item-interface ))))
916         ))
917
918     (SeparationItem
919      . (
920         (meta . ((interfaces . (spacing-interface separation-item-interface item-interface ))))
921         ))
922
923     (SeparatingGroupSpanner
924      . (
925         (spacing-procedure . ,Separating_group_spanner::set_spacing_rods)
926         (meta . ((interfaces . (spacing-interface separation-spanner-interface spanner-interface))))
927         ))
928
929     (SustainPedal
930      . (
931         (no-spacing-rods . #t)
932         (molecule-callback . ,Sustain_pedal::brew_molecule)
933         (self-alignment-X . 0)
934         (direction . 1)
935         (padding . 0.0)  ;; padding relative to SustainPedalLineSpanner
936         (pedal-type . text)
937         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
938         (meta . ((interfaces . (piano-pedal-interface text-spanner-interface text-interface self-alignment-interface font-interface item-interface))))
939         ))
940
941     (SustainPedalLineSpanner 
942      . (
943         (axes . (1))
944         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
945         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
946         
947         (padding . 1.2)
948         (minimum-space . 1.0)
949         (direction . -1)
950         (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
951         ))
952
953     (System
954      . (
955         (axes . (0 1))
956         (X-extent-callback . ,Axis_group_interface::group_extent_callback)
957         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
958         (meta . ((interfaces . (system-interface axis-group-interface spanner-interface))))
959         ))
960
961     (SystemStartBrace
962      . (
963         (glyph . "brace")
964         (molecule-callback . ,System_start_delimiter::brew_molecule)
965         (collapse-height . 5.0)
966         (font-family . braces)
967         (Y-extent-callback . #f)
968         (meta . ((interfaces . (system-start-delimiter-interface font-interface))))
969         ))
970
971     (SystemStartBracket
972      . (
973         (Y-extent-callback . #f)
974         (molecule-callback . ,System_start_delimiter::brew_molecule)
975         (glyph . "bracket")
976         (arch-height . 1.5)
977         (arch-angle . 50.0)
978         (arch-thick . 0.25)
979         (arch-width . 1.5)
980         (bracket-collapse-height . 1)
981         (thickness . 0.25)
982         (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
983         ))
984
985     (SystemStartBar
986      . (
987         (Y-extent-callback . #f)
988         (molecule-callback . ,System_start_delimiter::brew_molecule)
989         (glyph . "bar-line")
990         (thickness . 1.6)
991         (after-line-breaking-callback . ,System_start_delimiter::after_line_breaking)
992         (meta . ((interfaces . (system-start-delimiter-interface spanner-interface))))
993         ))
994
995     (TextScript
996      . (
997         (molecule-callback . ,Text_item::brew_molecule)
998         (no-spacing-rods . #t)
999         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1000         (direction . -1)
1001         (padding . 0.5)
1002         (script-priority . 200)
1003         ;; todo: add X self alignment?
1004         (baseline-skip . 2)
1005         (font-family . roman)
1006         (meta . ((interfaces . (text-script-interface text-interface side-position-interface font-interface item-interface ))))
1007         ))
1008
1009     (TextSpanner
1010      . (
1011         (molecule-callback . ,Text_spanner::brew_molecule)
1012         (font-family . roman)
1013         (type . line)
1014
1015         ;; urg, only for (de)cresc. text spanners
1016         (if-text-padding . 1.0)
1017         (width-correct . -1)
1018
1019         (direction . 1)
1020         (meta . ((interfaces . (text-spanner-interface side-position-interface font-interface spanner-interface))))             
1021         ))
1022     
1023     (TabNoteHead
1024      . (
1025         (font-family . roman)
1026         (style . default)
1027         (molecule-callback . ,tablature-molecule-callback)
1028         (Y-offset-callbacks  . (,Staff_symbol_referencer::callback))
1029         (stem-attachment-function . ,tablature-stem-attachment-function)
1030         (meta . ((interfaces
1031                   . (rhythmic-head-interface
1032                      font-interface
1033                      note-head-interface staff-symbol-referencer-interface
1034                      text-interface item-interface ))))
1035         ))
1036
1037
1038     (Tie
1039      . (
1040         (molecule-callback . ,Tie::brew_molecule)
1041         (spacing-procedure . ,Spanner::set_spacing_rods)
1042         (staffline-clearance . 0.35)
1043         (details . ((ratio . 0.333) (height-limit . 1.0)))
1044         (thickness . 1.2)
1045         (x-gap . -0.1)
1046         (y-offset . 0.6)
1047         (minimum-length  . 2.5)
1048         (meta . ((interfaces . (tie-interface spanner-interface))))
1049         ))
1050
1051     (TieColumn
1052      . (
1053         (after-line-breaking-callback . ,Tie_column::after_line_breaking)
1054         (X-extent-callback . ())
1055         (Yoo-extent-callback . ())      
1056         (meta . ((interfaces . (tie-column-interface spanner-interface))))
1057         ))
1058
1059     (TimeSignature
1060      . (
1061         (molecule-callback . ,Time_signature::brew_molecule)
1062         (break-align-symbol . time-signature)
1063         (break-visibility . ,all-visible)
1064         (space-alist . (
1065                         (first-note . (extra-space . 2.0))
1066                         (staff-bar .  (minimum-space . 2.0))
1067                         ))
1068         (breakable . #t)
1069         (style . C)
1070         (font-family . number)
1071         (meta . ((interfaces . (time-signature-interface break-aligned-interface font-interface item-interface ))))
1072         ))
1073
1074     (TupletBracket
1075      . (
1076         (gap . 2.0)
1077         (padding . 0.9)
1078         (thickness . 1.6)
1079         (edge-widen . (0.0 . 0.0))
1080         (edge-height . (0.7 . 0.7))
1081         (shorten-pair . (-0.2 . -0.2))
1082         (before-line-breaking-callback . ,Tuplet_bracket::before_line_breaking)
1083         (after-line-breaking-callback . ,Tuplet_bracket::after_line_breaking)
1084         (molecule-callback . ,Tuplet_bracket::brew_molecule)
1085         (font-family . roman)
1086         (font-shape . italic)
1087
1088         (font-relative-size . -1)
1089         (meta .  ((interfaces . (text-interface tuplet-bracket-interface font-interface spanner-interface))))
1090         ))
1091
1092     (UnaCordaPedal
1093      . (
1094         (molecule-callback . ,Text_item::brew_molecule)
1095         (font-family . roman)
1096         (font-shape . italic)
1097         (no-spacing-rods . #t)
1098         (self-alignment-X . 0)
1099         (direction . 1)
1100         (pedal-type . text)
1101         (padding . 0.0)  ;; padding relative to UnaCordaPedalLineSpanner
1102         (X-offset-callbacks . (,Self_alignment_interface::aligned_on_self))
1103         (meta . ((interfaces . (text-interface self-alignment-interface font-interface item-interface ))))
1104         ))
1105
1106     (UnaCordaPedalLineSpanner 
1107      . (
1108         (axes . (1))
1109         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
1110         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1111         
1112         (padding . 1.2)
1113         (minimum-space . 1.0)
1114         (direction . -1)
1115         (meta . ((interfaces . (piano-pedal-interface axis-group-interface side-position-interface spanner-interface))))
1116         ))
1117
1118     (VoltaBracket
1119      . (
1120         (molecule-callback . ,Volta_bracket_interface::brew_molecule)
1121         (direction . 1)
1122         (padding . 1)
1123         (font-style . volta)
1124         (Y-offset-callbacks . (,Side_position_interface::aligned_side))
1125         (thickness . 1.6)  ;  stafflinethickness
1126         (height . 2.0) ; staffspace;
1127         (minimum-space . 5)
1128         (font-family . number)
1129         (font-relative-size . -2)
1130         (meta . ((interfaces . (volta-bracket-interface text-interface side-position-interface font-interface spanner-interface))))
1131         ))
1132     
1133     (VerticalAlignment
1134      . (
1135         (axes . (1))
1136         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)
1137         (stacking-dir . -1)
1138         (meta . ((interfaces . (align-interface axis-group-interface spanner-interface))))
1139         ))
1140
1141     (VerticalAxisGroup
1142      . (
1143         (axes . (1))
1144         (Y-extent-callback . ,Axis_group_interface::group_extent_callback)      
1145         
1146         (meta . ((interfaces . (axis-group-interface spanner-interface))))
1147         ))
1148    )
1149  )
1150
1151
1152
1153
1154 (define (completize-grob-entry x)
1155   "transplant assoc key into 'name entry of 'meta of X
1156 "
1157   (let* ((name-sym  (car x))
1158          (grob-entry (cdr x))
1159          (metaentry (cdr (assoc 'meta grob-entry)))
1160          (ifaces-entry
1161           (cdr (assoc 'interfaces metaentry)))
1162
1163         )
1164     (set! metaentry (assoc-set! metaentry 'name name-sym))
1165     (set! metaentry (assoc-set! metaentry 'interfaces
1166                                 (cons 'grob-interface ifaces-entry)))
1167     (set! grob-entry (assoc-set! grob-entry 'meta metaentry))
1168     (cons name-sym grob-entry)))
1169
1170 (set! all-grob-descriptions (map completize-grob-entry all-grob-descriptions))
1171
1172
1173
1174                                         ;  (display  (map pair? all-grob-descriptions))
1175
1176
1177 ;; make sure that \property Foo.Bar =\turnOff doesn't complain
1178
1179 (map (lambda (x)
1180                                         ; (display (car x)) (newline)
1181
1182        (set-object-property! (car x) 'translation-type? list?)
1183        (set-object-property! (car x) 'is-grob? #t))
1184      all-grob-descriptions)
1185
1186
1187 (set! all-grob-descriptions (sort all-grob-descriptions alist<?))