]> git.donarmstrong.com Git - lilypond.git/blob - scm/define-music-properties.scm
Fix some bugs in the dynamic engraver and PostScript backend
[lilypond.git] / scm / define-music-properties.scm
1 ;;;; music-property-description.scm -- part of generated backend documentation
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 (define (music-property-description symbol type? description)
9   (if (not (equal? #f (object-property symbol 'music-doc)))
10       (ly:error (_ "symbol ~S redefined") symbol))
11   (set-object-property! symbol 'music-type? type?)
12   (set-object-property! symbol 'music-doc description)
13   symbol)
14
15 (define-public all-music-properties
16   (map
17    (lambda (x) (apply music-property-description x))
18    `(
19      (iterator-ctor ,procedure? "Function to construct music-event-iterator object for this Music")
20      (duration ,ly:duration? "Duration of this note/lyric.")
21      (metronome-count ,number? "How many beats in a minute?")
22      (span-type ,string? "What kind of spanner should be created?
23
24 TODO: consider making type into symbol") 
25      (absolute-octave ,integer?
26                       "The absolute octave for a octave check note.")
27      (articulations ,ly:music-list?
28                     "Articulation events specifically for this note.")
29      (articulation-type ,string? "key for script definitions alist.
30
31 TODO: consider making type into symbol ")
32      (augmented ,boolean? "This figure is for an augmented figured bass (with +) sign.")
33      (associated-context ,string? "Name of the Voice context associated with this \\newaddlyrics section")
34      (bass ,boolean? "Set if this note is a bass note in a chord")
35      (break-penalty ,number? "Penalty for line break hint.")
36      (break-permission ,symbol? "Whether to allow, forbid or force a line break.")
37      (cautionary ,boolean? "If set, this alteration needs cautionary accidental")
38      (change-to-id ,string? "name of the context to change to ")
39      (change-to-type ,symbol? "type of the context to change to.")
40      (compress-procedure ,procedure? "compress this music expression. Argument 1: the music, arg 2: factor")
41      (context-id ,string? "name of context")
42      (context-type ,symbol?  "type of context")
43      (create-new ,boolean? "Create a fresh context.") 
44      (descend-only ,boolean? "If set, this @code{\\context} will only descend in the context tree.")
45      (denominator ,integer? "denominator in a time signature")
46      (digit ,integer? "digit for fingering")
47      (diminished ,boolean? "This bass figure should be slashed.")
48      (direction ,ly:dir? "Print this up or down?")
49      (drum-type ,symbol? "Which percussion instrument to play this note on.")
50      (error-found ,boolean? "If true, a parsing error was found in this expression")
51      (element ,ly:music? "The single child of a Music_wrapper music object, or the body of a repeat.")
52      (elements ,ly:music-list? "A list of elements for sequential of simultaneous music, or the alternatives of repeated music. ")
53      (expected-beam-count ,integer? "Expected number of non-tremolo beams in a tremolo repeat")
54      (force-accidental ,boolean? "If set, a cautionary accidental should always be printed on this note")
55      (grob-property ,symbol? "The symbol of the grob property to set. ")
56      (grob-property-path ,list? "A list of symbols, locating a nested grob property, e.g. (beamed-lengths details). ")
57      (grob-value ,scheme? "The value of the grob property to set")
58      (input-tag ,scheme? "Arbitrary marker to relate input and output")
59      (inversion ,boolean? "If set, this chord note is inverted.")
60      (label ,markup? "label of a mark.")
61      (last-pitch ,ly:pitch? "The last pitch after relativization.")
62      (length ,ly:moment? "The duration of this music")
63      (length-callback ,procedure? "How to compute the duration of this music. This property can only be defined as initializer in @file{define-music-types.scm}.")
64      (name ,symbol? "Name of this music object")
65      (no-continuation ,boolean? "If set, disallow continuation lines")
66      (numerator ,integer? "numerator of a time signature")
67      (once ,boolean? "Apply this operation only during one time step?")
68      (octavation ,integer? "This pitch was octavated by how many octaves? For chord inversions, this is negative.")
69      (origin ,ly:input-location? "where was this piece of music defined?")
70      (parenthesize ,boolean? "Enclose resulting objects in parentheses?")
71      (pitch ,ly:pitch? "the pitch of this note")
72      (pitch-alist ,list? "list of pitches jointly forming the scale of a key signature")
73      (pop-first ,boolean? "Do a revert before we try to do a override on some grob property.")
74      (procedure ,procedure?
75                 "The function to run with \\applycontext.
76 It must take a single argument, being the context.")
77      (property-operations ,list?
78                           "Do these operations for instantiating the context.")
79      (quoted-events ,vector? "A vector of with moment/event-list entries.")
80      (quoted-music-name ,string? "The name of the voice to quote.")
81      (quoted-voice-direction ,ly:dir? "Should the quoted voice be up-stem or down-stem?")
82      (quoted-context-type ,symbol? "The name of the context to direct quotes to, eg., @code{Voice}.")
83      (quoted-context-id ,string? "The id of the context to direct quotes to, eg., @code{cue}.")
84      (quoted-transposition ,ly:pitch? "The pitch used for the quote, overriding \\transposition")
85      (to-relative-callback ,procedure? "How to transform a piece of music to relative pitches")
86      (tweaks ,list? "An alist of properties to override in the backend
87 for the grob made of this event.")
88      
89      (repeat-count  ,integer? "do a @code{\repeat} how ofen?")
90      (span-direction ,ly:dir? "Does this start or stop a spanner?")
91      (split-list ,list? "splitting moments for part combiner.")
92      (start-callback ,procedure? "Function to compute the negative
93 length of starting grace notes.  This property can only be defined as
94 initializer in @file{define-music-types.scm}.")
95      (string-number ,integer? "The number of the string in a StringNumberEvent")
96      (symbol ,symbol? "Grob name to perform an override/revert on.")
97      (tags ,list? "List of symbols that for denoting extra details,
98 e.g. @code{\\tag #'part ...} could tag a piece of music as only being active in a part.")
99      (text-type ,symbol? "Particular type of text script (e.g. finger, dynamic).")
100      
101      (text ,markup? "markup expression to be printed")
102      (tempo-unit ,ly:duration? "The unit for the metronome count.")
103      (tonic ,ly:pitch? "Base of the scale")
104      (tremolo-type ,integer? "speed of tremolo, e.g. 16 for c4:16")
105      (trill-pitch ,ly:pitch? "Pitch of other note of the trill.")
106      (type ,symbol? "The type of this music object. Determines iteration in some cases.")
107      (types ,list? "The types of this music object; determines by what
108 engraver this music expression is processed.")
109      (value ,scheme? "Assignment value for a
110 translation property")
111      (void ,boolean? "If this property is #t, then the music expression is to be
112 discarded by the toplevel music handler.")
113      (what ,symbol? "What to change for auto-change. FIXME, naming")
114      (part-combine-status ,symbol?
115                           "Change to what kind of state? Options are
116 solo1, solo2 and unisono")
117
118      (figure ,integer? "a bass figure")
119      (alteration ,number? "alteration for figured bass")
120      (bracket-start ,boolean? "start a bracket
121 here. TODO: use SpanEvents?")
122      (bracket-stop ,boolean? "stop a bracket here.")
123      (untransposable ,boolean? "If set, this music is not transposed.")
124      )))