]> git.donarmstrong.com Git - lilypond.git/blob - init/property.ly
release: 1.0.4
[lilypond.git] / init / property.ly
1 % property.ly
2 % list of properties that lily recognises
3 % and some shorthands (ugh)
4
5 %{
6
7 PROPERTIES
8
9 name                    value   effect                  shorthand
10
11 [Voice]
12 ydirection              -1      force stem down         \stemdown
13 ydirection              0       stem direction free     \stemboth
14 ydirection              1       force stem up           \stemup
15 pletvisibility          0       show nothing
16 pletvisibility          1       show number
17 pletvisibility          2       show number, and bracket-if-no-beam
18 pletvisibility          4       show number, and bracket
19
20 slurdash                0       normal slurs
21 slurdash                1       dotted slurs
22 slurdash                >1      dashed slurs
23
24 slurydirection          -1      force stem down         \slurdown
25 slurydirection          0       stem direction free     \slurboth
26 slurydirection          1       force stem up           \slurup
27
28 slurydirection          -1      force stem down         \slurdown
29 slurydirection          0       stem direction free     \slurboth
30 slurydirection          1       force stem up           \slurup
31
32 textalignment           -1      left alignment of text
33 textalignment           0       center alignment of text
34 textalignment           1       right alignment of text
35
36 [Score?]
37 beamslopedamping        0       no damping              \beamslopeproportional  
38 beamslopedamping        1       damping1)               \beamslopedamped
39 beamslopedamping        100000  zero slope              \beamslopezero
40
41 [Score?]
42 beamquantisation        0       no quantisations        \beamposfree
43 beamquantisation        1       quantise pos and slope  \beamposnormal
44 beamquantisation        2       quantise avoide wedge2) \beampostraditional
45
46 [Staff]
47 specialaccidentals      0       Accidental for all octaves      \normalkey
48 specialaccidentals      1       Accidental only for specified octave    \specialkey
49
50
51 [Staff?]
52 instrument              ascii   midi instrument table lookup
53
54
55 1) after beam slope damping table suggested in [Wanske]
56 2) [Wanske] as well as [Ross] suggests that beams sloped upward must not 
57    start sitting on a staffline, and beams sloped downward must not hang 
58    from a staffline (similar for beam-ends).  This would create a wedge
59    that is traditionally being avoided because it could easily be filled-up 
60    with ink.
61    However, avoiding these wedges restricts the freedom of beams quite a lot 
62    while they don't seem to be a problem in modern printing.
63    In no piece of sheetmusic engraved after 1953 (Baerenreiter) i've seen 
64    these wedges being avoided.
65
66 %}
67
68 %hmm, (these) abbrevs suck, imo
69 % i guess they're meant as some form of doco
70 % that's what i use them for...
71 % should compile a list with recognised properties!
72 stemup = {
73         \skip 1*0;
74         % Stupid hack to make < { \stemup } > work
75         \property Voice.ydirection = \up 
76         }
77 stemboth= {
78         \skip 1*0;
79         \property Voice.ydirection = \center
80 }
81 stemdown = {    
82         \skip 1*0;
83         \property Voice.ydirection = \down
84 }
85 slurup = {
86         \skip 1*0;
87         \property Voice.slurydirection = \up 
88         }
89 slurboth= {
90         \skip 1*0;
91         \property Voice.slurydirection = \center
92 }
93 slurdown = {    
94         \skip 1*0;
95         \property Voice.slurydirection = \down
96 }
97
98 shifton =       \property Voice.hshift = 1
99 shiftoff =      \property Voice.hshift = 0
100
101 onevoice = {    
102         \stemboth \shiftoff     
103 }
104
105 voiceone = {    
106         \type Voice = one 
107         \skip 1*0;
108         \stemup
109 }
110
111 voicetwo = {    
112         \type Voice = two
113         \skip 1*0;
114         \stemdown
115 }
116
117 voicethree = {  
118         \type Voice = three
119         \skip 1*0;
120         \stemup
121
122 }
123
124 voicefour = {   
125         \type Voice = four
126         \skip 1*0;
127         \stemdown
128         \shifton
129 }
130
131 onestaff = {    
132         \translator Staff=one
133         \skip 1*0;
134 }
135
136 staffone = {    
137         \translator Staff=one
138         \skip 1*0;
139         \property Staff.ydirection = \center
140         \property Staff.hshift = 0
141 }
142
143 stafftwo = {    
144         \translator Staff=two
145         \skip 1*0;
146         \property Staff.ydirection = \center
147         \property Staff.hshift = 0
148 }
149
150 staffthree = {  
151         \translator Staff=three
152         \skip 1*0;
153         \property Staff.ydirection = \center
154         \property Staff.hshift = 0
155 }
156
157 stafffour = {   
158         \translator Staff=four
159         \skip 1*0;
160         \property Staff.ydirection = \center
161         \property Staff.hshift = 0
162 }
163
164 % ugh, cluttering global namespace...
165 none=0
166 free=0
167 normal=1
168 traditional=2
169 infinity=10000
170
171 beamslopeproportional = {
172         \property Score.beamslopedamping = \none
173 }
174
175 beamslopedamped = {
176         \property Score.beamslopedamping = \normal
177 }
178
179 beamslopezero = {
180         \property Score.beamslopedamping = \infinity
181 }
182
183 % this sucks, you'd want to pass an array, at least
184 % (or embedded code: you still can't dictate the slope / stemlength)
185 beamposfree = {
186         \property Score.beamquantisation = \none
187 }
188
189 beamposnormal = {
190         \property Score.beamquantisation = \normal
191 }
192
193 beampostraditional = {
194         \property Score.beamquantisation = \traditional
195 }
196
197 slurnormal = {
198         \property Voice.slurdash = 0
199 }
200
201 slurdotted = {
202         \property Voice.slurdash = 1
203 }
204
205 %{
206  for grace note hack, see input/test/grace.ly
207 %}
208 pletoff = {
209         \property Voice.pletvisibility = 0
210 }
211 pleton = {
212         \property Voice.pletvisibility = 2
213 }
214 tiny  = {
215         \property Voice.fontsize= "-2"
216         \pletoff %urg
217 }
218
219 small  = {
220         \property Voice.fontsize= "-1"
221 }
222
223 normalsize = {
224         \property Voice.fontsize= "0"
225         \pleton %urg
226 }
227
228 %{
229   [urg: try at] temporary grace note hack
230   the total visible duration of the grace notes must be half
231   the duration of the 'at' note: e.g.:
232
233   \grace b8 \graceat c4 \ecarg
234   \grace c16 b16 \graceat c4 \ecarg
235
236 grace = {
237         \tiny
238 % it would be so cool not to have to specify these factors each time...
239 % :-(
240         \property Voice.pletvisibility = 0
241         \[1/16
242 }
243
244 graceat = \melodic {
245         \normalsize
246         \property Voice.pletvisibility = 0
247         \] \[31/32
248 }
249
250 ecarg =  \melodic {
251         \property Voice.pletvisibility = 0
252         \]
253         \property Voice.pletvisibility = 2
254 }
255 %}
256
257 normalkey = {
258         \property Staff.specialaccidentals = 0
259 }
260
261 specialkey = {
262         \property Staff.specialaccidentals = 1
263 }
264