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