]> git.donarmstrong.com Git - lilypond.git/blob - scm/define-music-types.scm
new file.
[lilypond.git] / scm / define-music-types.scm
1 ;;;; define-music-types.scm --
2 ;;;;
3 ;;;;  source file of the GNU LilyPond music typesetter
4 ;;;; 
5 ;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
6 ;;;;                 Jan Nieuwenhuizen <janneke@gnu.org>
7
8 ;; TODO: should link back into user manual.
9
10 (define (mm-rest-child-list music)
11   "Check if we have R1*4-\\markup { .. }, and if applicable convert to
12 a property set for MultiMeasureRestNumber."
13   (let ((location (ly:music-property music 'origin))
14         (duration (ly:music-property music 'duration)))
15     (list (make-music 'BarCheck
16                       'origin location)
17           (make-event-chord (cons (make-music 'MultiMeasureRestEvent
18                                               'origin location
19                                               'duration duration)
20                                   (ly:music-property music 'articulations)))
21           (make-music 'BarCheck
22                       'origin location))))
23
24 (define-public music-descriptions
25   `(
26     (AbsoluteDynamicEvent
27      . (
28         (description . "Creates a dynamic mark.
29
30 Syntax: @var{note}@code{\\x},
31 where x is one of \\ppp, \\pp, \\p, \\mp, \\mf, \\f, \\ff, \\fff.")
32         (types . (general-music event dynamic-event absolute-dynamic-event))
33         ))
34     (ApplyContext
35      . (
36         (description . "Call the argument with the current context during interpreting phase")
37         (types . (general-music apply-context))
38         (iterator-ctor . ,ly:apply-context-iterator::constructor)
39         ))
40     (ApplyOutputEvent
41      . (
42         (description . "
43 Call the argument with all current grobs during interpreting phase.
44
45 Syntax
46
47 \\applyOutput #'Context FUNC
48
49 arguments to func are 1. the grob, 2. the originating context,
50 3. context where FUNC is called.
51
52 ")
53         (types . (general-music event layout-instruction))
54         ))
55     (ArpeggioEvent 
56      . (
57         (description .  "Make an arpeggio on this note.
58
59 Syntax:
60 @var{note}-@code{\\arpeggio}")
61         (types . (general-music arpeggio-event event))
62         ))
63
64     ;; todo: use articulation-event for slur as well.
65     ;; separate non articulation scripts  
66     (ArticulationEvent
67      . (
68         (description .  "Adds an articulation marking to a note.  
69
70 Syntax:
71 @var{note}@code{X}@code{Y}, where X is a direction (up @code{^}, down
72 @code{_}, or LilyPond's choice (no direction specified)), and where Y
73 is an articulation (such as @code{-.}, @code{->}, @code{\\tenuto},
74 @code{\\downbow}).  See the user manual for details.")
75
76         (types . (general-music event articulation-event script-event))
77         )) 
78     (AutoChangeMusic
79      . (
80         (description .  "Used for making voices that switch between piano staves automatically.")
81         (iterator-ctor . ,ly:auto-change-iterator::constructor)
82         (start-callback . ,ly:music-wrapper::start-callback)
83         (length-callback . ,ly:music-wrapper::length-callback)
84         (types . (general-music music-wrapper-music auto-change-instruction))
85         ))
86     (BarCheck
87      . (
88         (description .
89                      "Check whether this music coincides with the start of the measure.")
90         (types . (general-music bar-check))
91         (iterator-ctor . ,ly:bar-check-iterator::constructor)
92         ))
93     (BassFigureEvent
94      . (
95         (description .  "Print a bass-figure text")
96
97         (types . (general-music event rhythmic-event bass-figure-event))
98         ))
99     (BeamEvent
100      . (
101         (description .  "Starts or stops a beam.  
102
103 Syntax for manual control:
104 c8-[ c c-] c8")
105         (types . (general-music event beam-event span-event))
106         ))
107
108     (BendAfterEvent
109      . ((description . "A drop/fall/doit jazz articulation")
110         (types . (general-music bend-after-event event))))
111
112     (BreakEvent
113      . (
114         (description .  "Create a line break, Syntax: \\break or page break, Syntax: \\pagebreak.")
115         
116         (types . (general-music break-event event))
117         ))
118     (BreathingSignEvent
119      . (
120         (description .  "Creates a `breath mark' or `comma'.  
121
122 Syntax:
123 @var{note}\\breathe.")
124
125         (types . (general-music event breathing-event))
126         )) 
127     (BusyPlayingEvent
128      . (
129         (description .  "Used internally to signal beginning and ending of notes.")
130
131         (types . (general-music event busy-playing-event))
132         ))
133     (ContextChange
134      . (
135         (description .  "Change staffs in Piano staff. 
136
137 Syntax @code{\\translator Staff = @var{new-id}}.")
138         (iterator-ctor . , ly:change-iterator::constructor)
139         (types . (general-music translator-change-instruction))
140         ))
141
142     (ClusterNoteEvent
143      . ((description .  "A note that is part of a cluster.")
144
145         ;; not a note-event, to ensure that Note_engraver doesn't eat it. 
146         (types . (general-music cluster-note-event melodic-event rhythmic-event event))
147         ))
148     
149     (ContextSpeccedMusic
150      . (
151         (description .  "Interpret the argument music within a specific context.")
152         (iterator-ctor . ,ly:context-specced-music-iterator::constructor)
153         (length-callback . ,ly:music-wrapper::length-callback)
154         (start-callback . ,ly:music-wrapper::start-callback)
155         (types . (context-specification general-music music-wrapper-music))
156         ))
157     
158     (CrescendoEvent
159      . (
160         (description .  "Begins or ends a crescendo.  
161
162 Syntax: @var{note}\\cr
163 ... @var{note}\\rc (you can also use \\<, \\!, \\cresc, and
164 \\endcresc.  See the user manual for details.).")
165
166         (types . (general-music dynamic-event crescendo-event event))
167         )) 
168     (DecrescendoEvent
169      . (
170         (description .  "See @ref{CrescendoEvent}.")
171
172         (types . (general-music dynamic-event decrescendo-event event))
173         ))
174     
175     (ExtenderEvent
176      . (
177         (description .  "Extend lyrics.")
178
179         (types . (general-music extender-event event))
180         ))
181
182     (Event
183      . (
184         (description .  "Atomic music event.")
185         (types . (general-music event))
186         ))
187         
188     (EventChord
189      . (
190         (description .  "Internally used to group a set of events.")
191         (iterator-ctor . ,ly:event-chord-iterator::constructor)
192         (length-callback . ,ly:music-sequence::maximum-length-callback)
193         (to-relative-callback . ,ly:music-sequence::event-chord-relative-callback)
194         (types . (general-music event-chord simultaneous-music))
195         ))
196
197     
198     (FingerEvent
199      . (
200         (description . "Specify what finger to use for this note.")
201         (types . (general-music fingering-event event))
202         ))
203     (BeamForbidEvent
204      . (
205         (description . "Specify that a note may not auto-beamed ")
206         (types . (general-music event beam-forbid-event))
207         ))
208     (GlissandoEvent
209      . (
210         (description .  "Start  a glissando on this note.")
211         (types . (general-music glissando-event event))
212         ))
213     
214     (GraceMusic
215      . (
216         (description .  "Interpret the argument as grace notes. ")
217         (start-callback . ,ly:grace-music::start-callback)
218         (length . ,ZERO-MOMENT)
219         (iterator-ctor . ,ly:grace-iterator::constructor)
220         (types . (grace-music music-wrapper-music general-music))
221         ))
222     (NoteGroupingEvent
223      . (
224         (description . "Start or stop grouping brackets.")
225         (types . (general-music event note-grouping-event))
226         ))
227     (HarmonicEvent
228      . (
229         (description . "Mark a note as harmonic")
230         (types . (general-music event harmonic-event))
231         ))
232     (HyphenEvent
233      . (
234         (description .  "A hyphen between lyric syllables.")
235
236         (types . (general-music hyphen-event event))
237         ))
238     
239     (KeyChangeEvent
240      . (
241         (description .  "Change the key signature. 
242
243 Syntax: @code{\\key } @var{name} @var{scale}.")
244         (to-relative-callback . ,(lambda (x p) p))
245         (types . (general-music key-change-event event))
246         ))
247     (LaissezVibrerEvent
248      . ((description . "Don't damp this chord.
249
250 Syntax: @var{note}\\laissezVibrer.")
251
252         (types . (general-music event laissez-vibrer-event))
253         ))
254     (LigatureEvent
255      . (
256         (description .  "Start or end a ligature.")
257         (span-type . ligature)
258         (types . (general-music span-event ligature-event event))
259         ))
260     (LineBreakEvent
261      . (
262         (description .  "Allow, forbid or force a line break.")
263         (types . (general-music break-event event))
264         ))
265     
266     (LyricCombineMusic
267      . (
268         (description .  "Align lyrics to the start of notes.
269
270 Syntax @var{\\lyricsto }@var{voicename} @var{lyrics}.")
271         (length . ,ZERO-MOMENT)
272         (types . (general-music lyric-combine-music))
273         (iterator-ctor . ,ly:lyric-combine-music-iterator::constructor)
274         ))
275
276     (LyricEvent
277      . (
278         (description .  "A lyric syllable. Must be entered in lyrics mode, i.e.
279 @code{\\lyrics @{ twinkle4 twinkle4 @} } .")
280
281         (types . (general-music rhythmic-event lyric-event event))
282         ))
283     (MarkEvent
284      . (
285         (description .  "Insert a rehearsal mark. 
286
287 Syntax: @code{\\mark} @var{marker},
288 e.g. @code{\\mark \"A\"}.")
289
290         (types . (general-music mark-event event))
291         ))
292     (MelismaPlayingEvent
293      . (
294         (description .  "Used internally to signal melismas.")
295         (types . (general-music melisma-playing-event event))
296         ))
297     (ManualMelismaEvent
298      . (
299         (description .  "Start or stop a melisma.
300
301 Syntax: @code{c4\\melisma d\\melismaEnd}.")
302         (types . (general-music melisma-span-event event))
303         ))
304
305     (MultiMeasureRestMusic
306      . (
307         (description . "Rests that may be compressed into Multi rests. 
308
309 Syntax
310 @code{R2.*4} for 4 measures in 3/4 time.")
311         (iterator-ctor . ,ly:sequential-iterator::constructor)
312         (elements-callback . ,mm-rest-child-list)
313         (types . (general-music multi-measure-rest))
314         ))
315
316     (MultiMeasureRestEvent
317      . (
318         (description . "Used internally by MultiMeasureRestMusic to signal rests")
319         (types . (general-music event rhythmic-event multi-measure-rest-event))
320         ))
321     
322     (MultiMeasureTextEvent
323      . (
324         (description . "Texts on mm rests. 
325
326 Syntax
327 @code{R-\\markup @{ \\roman \"bla\" @}}. Note the explicit font switch.")
328         (types . (general-music event multi-measure-text-event))
329         ))
330
331     (Music
332      . (
333         (description .  "Generic type for music expressions.")
334
335         (types . (general-music)) 
336         ))
337     (NoteEvent
338      . (
339         (description .  "A note.")
340         (types . (general-music event note-event rhythmic-event melodic-event))
341         ))
342     
343     (OverrideProperty
344      . (
345         (description .  "Extend the definition of a graphical object.
346
347 SYNTAX
348
349 @code{\\override [ @var{Ctxt} . ] @var{Obj} @var{prop} = @var{val}}
350 ")
351         (types . (general-music layout-instruction))
352         (iterator-ctor . ,ly:push-property-iterator::constructor)
353         ))
354     (PageBreakEvent
355      . (
356         (description .  "Allow, forbid or force a page break.")
357         (types . (general-music break-event event))
358         ))
359     (PageTurnEvent
360      . (
361         (description .  "Allow, forbid or force a page turn.")
362         (types . (general-music break-event event))
363         ))
364     (PartCombineMusic
365      . (
366         (description .  "Combine two parts on a staff, either merged or
367 as separate voices.")
368         (length-callback . ,ly:music-sequence::maximum-length-callback)
369         (start-callback . ,ly:music-sequence::minimum-start-callback)
370         (types . (general-music part-combine-music))
371         (iterator-ctor . ,ly:part-combine-iterator::constructor)
372         ))
373     (PhrasingSlurEvent
374      . (
375         (description . "Start or end phrasing slur. 
376
377 Syntax NOTE \\(  and \\) NOTE")
378         (types . (general-music span-event event phrasing-slur-event))
379         ))
380     
381     (PropertySet
382      . (
383         (description .  "Set a context property.
384
385 Syntax: @code{\\property @var{context}.@var{prop} = @var{scheme-val}}.")
386         (types . (layout-instruction general-music))
387         (iterator-ctor . ,ly:property-iterator::constructor)
388         ))
389
390     (PropertyUnset
391      . (
392         (description .  "Remove the definition of a context @code{\\property}.")
393
394         (types . (layout-instruction general-music))
395         (iterator-ctor . ,ly:property-unset-iterator::constructor)
396         ))
397
398     (PercentEvent
399      . (
400         (description .  "Used internally to signal percent repeats.")
401         (types . (general-music event percent-event))
402         ))
403
404     (PesOrFlexaEvent
405      . (
406         (description .  "Within a ligature, mark the previous and the
407 following note to form a pes (if melody goes up) or a flexa (if melody
408 goes down).")
409
410         (types . (general-music pes-or-flexa-event event))
411         ))
412
413     (QuoteMusic
414      . (
415         (description . "Quote preprocessed snippets of music. ")
416         (iterator-ctor . ,ly:music-wrapper-iterator::constructor)
417         (length-callback . ,ly:music-wrapper::length-callback)
418         (start-callback . ,ly:music-wrapper::start-callback)
419         (types . (general-music music-wrapper-music))
420         ))
421     
422     (RelativeOctaveCheck
423      . ((description . "Check if a pitch is in the correct octave.")
424         (to-relative-callback . ,ly:relative-octave-check::relative-callback)
425         (types . (general-music relative-octave-check))
426         ))
427     
428     (RepeatedMusic
429      . (
430         (description .  "Repeat music in different ways")
431         (types . (general-music repeated-music))
432         ))
433     (RepeatTieEvent
434      . (
435         (description . "Ties for starting a second volta bracket.")
436         (types . (general-music event repeat-tie-event))
437         ))
438     (RestEvent
439      . (
440         (description .  "A Rest. 
441
442 Syntax @code{r4} for a quarter rest. ")
443
444         (types . (general-music event rhythmic-event rest-event))
445         )) 
446     (RevertProperty
447      . (
448         (description .  "The opposite of @ref{OverrideProperty}: remove a
449 previously added property from a graphical object definition
450  ")
451
452         (types . (general-music layout-instruction))
453         (iterator-ctor . ,      ly:pop-property-iterator::constructor)
454         ))
455
456     (SequentialMusic
457      . (
458         (description .  "Music expressions concatenated. 
459
460 Syntax \\sequential @{..@} or simply @{..@} .")
461
462         (length-callback . ,ly:music-sequence::cumulative-length-callback)
463         (start-callback . ,ly:music-sequence::first-start-callback)
464         (elements-callback . ,(lambda (m) (ly:music-property m 'elements)))
465         (iterator-ctor . ,ly:sequential-iterator::constructor)
466         (types . (general-music sequential-music))
467         ))
468
469     (SoloOneEvent
470      . (
471         (description . "Print Solo.1")
472         (part-combine-status . solo1)
473         (types . (general-music event part-combine-event))
474         ))
475     (SoloTwoEvent
476      . (
477         (description . "Print Solo.2")
478         (part-combine-status . solo2)
479         (types . (general-music event part-combine-event))
480         ))
481     (UnisonoEvent
482      . ((description . "Print a2")
483         (part-combine-status . unisono)
484         (types . (general-music event part-combine-event))))
485     
486     (SimultaneousMusic
487      . (
488         (description .  "Music playing together.
489
490 SYNTAX
491
492 @code{ \\simultaneous @{ .. @}} or << .. >>.")
493
494         (iterator-ctor . ,ly:simultaneous-music-iterator::constructor)
495         (start-callback . ,ly:music-sequence::minimum-start-callback)
496         (length-callback . ,ly:music-sequence::maximum-length-callback)
497         (to-relative-callback . ,ly:music-sequence::simultaneous-relative-callback)
498         
499         (types . (general-music simultaneous-music))
500         ))
501     
502     (SlurEvent
503      . (
504         (description . "Start or end slur. 
505
506 Syntax NOTE(     and NOTE) ")
507
508         (types . (general-music span-event event slur-event))
509         ))
510     
511     (StaffSpanEvent
512      . ((description . "Start or  stop a staff symbol.")
513         (types . (general-music event span-event staff-span-event))
514      ))
515     
516     (StartPlayingEvent
517      . (
518         (description .  "Used internally to signal beginning of notes.")
519
520         (types . (general-music event start-playing-event))
521         ))
522     
523     (TextSpanEvent
524      . (
525         (description . "Start a text spanner like 8va.....|")
526         (types . (general-music span-event event text-span-event))
527         ))
528     
529     (TrillSpanEvent
530      . (
531         (description . "Start a trill spanner tr~~~")
532         (types . (general-music span-event event trill-span-event))
533         ))
534     
535     (TransposedMusic
536      . (
537         (description .  "Music that has been transposed.")
538         (iterator-ctor . ,ly:music-wrapper-iterator::constructor)
539         (start-callback . ,ly:music-wrapper::start-callback)
540         (length-callback . ,ly:music-wrapper::length-callback)
541         (to-relative-callback . ,ly:relative-octave-music::no-relative-callback)
542         (types . (music-wrapper-music general-music transposed-music))
543         ))
544
545     (TimeScaledMusic
546      . (
547         (description .  "Multiply durations, as in tuplets. 
548
549 Syntax @code{\\times @var{fraction} @var{music}}, e.g.
550 @code{\\times 2/3 @{ ... @}} for triplets.
551  ")
552         (length-callback . ,ly:music-wrapper::length-callback)
553         (start-callback . ,ly:music-wrapper::start-callback)
554         (iterator-ctor . ,ly:time-scaled-music-iterator::constructor)
555         (types . (time-scaled-music music-wrapper-music general-music))
556         ))
557
558     (TupletEvent
559      . (
560         (description .  "Used internally to signal where tuplet brackets start and stop.")
561         (types . (tuplet-spanner-event span-event event general-music))
562        ))
563
564     (UnrelativableMusic
565      . (
566         (description .  "Music that can not be converted from relative to absolute notation.
567 For example, transposed music.")
568         (to-relative-callback . ,ly:relative-octave-music::no-relative-callback)
569         (iterator-ctor . ,ly:music-wrapper-iterator::constructor)
570         (length-callback . ,ly:music-wrapper::length-callback)
571         (types . (music-wrapper-music general-music unrelativable-music))
572         ))
573
574     (RelativeOctaveMusic
575      . (
576         (description .  "Music that was entered in relative octave notation.")
577         (to-relative-callback . ,ly:relative-octave-music::relative-callback)
578         (iterator-ctor . ,ly:music-wrapper-iterator::constructor)
579         (length-callback . ,ly:music-wrapper::length-callback)
580         (start-callback . ,ly:music-wrapper::start-callback)
581         (types . (music-wrapper-music general-music relative-octave-music))
582         ))
583     (ScriptEvent
584      . (
585         (description .  "Add an articulation mark to a note. ")
586
587         (types . (general-music event))
588         ))
589
590     (SkipMusic
591      . (
592         (description .  "Filler that takes up duration, does not print anything, and also
593 does not create staffs or voices implicitly.
594
595
596
597 Syntax: @code{\\skip }@var{duration}.")
598         (length-callback . ,ly:music-duration-length)
599         (iterator-ctor . ,ly:simple-music-iterator::constructor)
600         (types . (general-music event rhythmic-event skip-event))
601         ))
602     
603     (SkipEvent
604      . (
605         (description .  "Filler that takes up duration, but does not print anything.
606
607
608
609 Syntax: @code{s}@var{duration}")
610
611         (types . (general-music event rhythmic-event skip-event))
612         ))
613
614     (SpacingSectionEvent
615      . ((description . "Start a new spacing section")
616         (types . (general-music event spacing-section-event))))
617      
618     (SpanEvent
619      . (
620         (description .  "Event for anything that is started at a different time than stopped.")
621
622         (types . (general-music event))
623         ))
624     
625     (SustainEvent
626      . (
627         (description . "Depress or release sustain pedal. ")
628         (types . (general-music event pedal-event sustain-pedal-event))
629         ))
630     
631     (SostenutoEvent
632      . (
633         (description . "Depress or release sostenuto pedal. ")
634         (types . (general-music event pedal-event sostenuto-pedal-event))
635         ))
636     
637     (UnaCordaEvent
638      . (
639         (description . "Depress or release una-corda pedal.")
640         (types . (general-music event pedal-event una-corda-pedal-event))
641         ))
642     
643     (StringNumberEvent
644      . (
645         (description .  "Specify on which string to play this note. 
646
647 Syntax: @code{\\@var{number}}.")
648
649         (types . (general-music string-number-event event))
650         )) 
651
652     (MetronomeChangeEvent
653      . (
654         (description .  "Change tempo setting (in beats per minute).")
655         (types . (general-music metronome-change-event tempo-event event))
656         ))
657     
658     (TextScriptEvent
659      . (
660         (description .  "")
661         (types . (general-music script-event text-script-event event))
662         )) 
663     (TieEvent
664      . (
665         (description .  "A tie.  Entered as @var{note}-~.")
666         (types . (general-music tie-event event))
667         ))
668     (TremoloEvent
669      . (
670         (description . "Un measured tremolo.")
671         (types . (general-music event tremolo-event))
672         ))
673     
674     (TremoloSpanEvent
675      . (
676         (description . "Tremolo over two stems")
677         (types . (general-music event span-event tremolo-span-event))
678         ))
679
680     (VoiceSeparator
681      . (
682         (description .  "Separate polyphonic voices in simultaneous music. 
683
684 Syntax: @code{\\\\}")
685
686         (types . (separator general-music))
687         ))
688
689     (VoltaRepeatedMusic
690      . (
691         (iterator-ctor . ,ly:volta-repeat-iterator::constructor)
692         (description . "")
693         (start-callback .  ,ly:repeated-music::first-start)
694         (length-callback . ,ly:repeated-music::volta-music-length)
695         (types . (general-music repeated-music volta-repeated-music))
696         ))
697     
698     (UnfoldedRepeatedMusic
699      . (
700         (iterator-ctor . ,ly:unfolded-repeat-iterator::constructor)
701         (description .  "")
702         (start-callback .  ,ly:repeated-music::first-start)
703         (types . (general-music repeated-music unfolded-repeated-music))
704         (length-callback . ,ly:repeated-music::unfolded-music-length)
705         ))
706     (PercentRepeatedMusic
707      . (
708         (description .  "Repeats encoded by percents.")
709         (iterator-ctor . ,ly:percent-repeat-iterator::constructor)
710         (start-callback .  ,ly:repeated-music::first-start)
711         (length-callback . ,ly:repeated-music::unfolded-music-length)
712         (types . (general-music repeated-music percent-repeated-music))
713         ))
714     
715     (TremoloRepeatedMusic
716      . (
717         (iterator-ctor . ,ly:chord-tremolo-iterator::constructor)
718         (description .  "Repeated notes denoted by tremolo beams.")
719         (start-callback .  ,ly:repeated-music::first-start)
720
721         ;; the length of the repeat is handled by shifting the note logs
722         (length-callback . ,ly:repeated-music::folded-music-length)
723         (types . (general-music repeated-music tremolo-repeated-music))
724         
725         ))
726     
727     (FoldedRepeatedMusic
728      . (
729         (description .  "Repeats with alternatives placed in parallel. ")
730         (iterator-ctor  . ,ly:folded-repeat-iterator::constructor)
731         (start-callback .  ,ly:repeated-music::minimum-start)
732         (length-callback . ,ly:repeated-music::folded-music-length)
733         (types . (general-music repeated-music folded-repeated-music))
734         ))
735     ))
736
737 (set! music-descriptions
738       (sort music-descriptions alist<?))
739
740 (define-public music-name-to-property-table (make-vector 59 '()))
741
742 ;; init hash table,
743 ;; transport description to an object property.
744 (set!
745  music-descriptions
746  (map (lambda (x)
747         (set-object-property! (car x)
748                               'music-description
749                               (cdr (assq 'description (cdr x))))
750         (let ((lst (cdr x)))
751           (set! lst (assoc-set! lst 'name (car x)))
752           (set! lst (assq-remove! lst 'description))
753           (hashq-set! music-name-to-property-table (car x) lst)
754           (cons (car x) lst)))
755       music-descriptions))
756
757 (define-safe-public (make-music name . music-properties)
758   "Create a music object of given name, and set its properties
759 according to `music-properties', a list of alterning property symbols
760 and values. E.g:
761   (make-music 'OverrideProperty 
762               'symbol 'Stem
763               'grob-property 'thickness
764               'grob-value (* 2 1.5))"
765   (if (not (symbol? name))
766       (ly:error (_ "symbol expected: ~S") name))
767   (let ((props (hashq-ref music-name-to-property-table name '())))
768     (if (not (pair? props))
769         (ly:error (_ "can't find music object: ~S") name))
770     (let ((m (ly:make-music props)))
771       (define (set-props mus-props)
772         (if (and (not (null? mus-props))
773                  (not (null? (cdr mus-props))))
774             (begin
775               (set! (ly:music-property m (car mus-props)) (cadr mus-props))
776               (set-props (cddr mus-props)))))
777       (set-props music-properties)
778       m)))
779
780 (define-public (make-repeated-music name)
781   (let* ((handle (assoc name '(("volta" . VoltaRepeatedMusic)
782                                ("unfold" . UnfoldedRepeatedMusic)
783                                ("percent" . PercentRepeatedMusic)
784                                ("tremolo" . TremoloRepeatedMusic)
785                                ("fold" . FoldedRepeatedMusic))))
786          (music-name (if (pair? handle)
787                          (cdr handle)
788                          (begin
789                            (ly:warning (_ "unknown repeat type `~S'") name)
790                            (ly:warning (_ "See music-types.scm for supported repeats"))
791                            'VoltaRepeatedMusic))))
792     (make-music music-name)))
793