]> git.donarmstrong.com Git - lilypond.git/blob - ly/property-init.ly
Add a TODO comment re grace note spacing.
[lilypond.git] / ly / property-init.ly
1 % property-init.ly
2
3 \version "2.10.0"
4
5 stemUp = \override Stem  #'direction = #UP
6 stemDown = \override Stem  #'direction = #DOWN 
7 stemNeutral= \revert Stem #'direction
8
9 slurUp = \override Slur  #'direction = #UP
10 slurDown = \override Slur  #'direction = #DOWN
11 slurNeutral = \revert Slur #'direction 
12
13 %% There's also dash, but setting dash period/length should be fixed.
14 slurDashed = {
15   \override Slur #'dash-period = #0.75
16   \override Slur #'dash-fraction = #0.4
17 }
18 slurDotted = {
19   \override Slur  #'dash-period = #0.75
20   \override Slur #'dash-fraction = #0.1
21 }
22 slurSolid = {
23   \revert Slur #'dash-period
24   \revert Slur #'dash-fraction
25 }
26
27
28 phrasingSlurUp = \override PhrasingSlur  #'direction = #UP
29 phrasingSlurDown = \override PhrasingSlur  #'direction = #DOWN
30 phrasingSlurNeutral = \revert PhrasingSlur #'direction 
31
32 shiftOn = \override NoteColumn  #'horizontal-shift = #1
33 shiftOnn = \override NoteColumn  #'horizontal-shift = #2
34 shiftOnnn = \override NoteColumn  #'horizontal-shift = #3
35 shiftOff = \revert NoteColumn #'horizontal-shift 
36
37 tieUp = \override Tie  #'direction = #UP
38 tieDown = \override Tie  #'direction = #DOWN
39 tieNeutral = \revert Tie #'direction 
40
41 tieDashed = {
42   \override Tie #'dash-period = #0.75
43   \override Tie #'dash-fraction = #0.4
44 }
45 tieDotted = {
46   \override Tie #'dash-period = #0.75
47   \override Tie #'dash-fraction = #0.1
48 }
49 tieSolid = {
50   \revert Tie #'dash-period
51   \revert Tie #'dash-fraction
52 }
53
54 setEasyHeads = \sequential {
55   \override NoteHead  #'stencil = #ly:note-head::brew-ez-stencil
56   \override NoteHead #'font-size = #-7
57   \override NoteHead #'font-family = #'sans
58   \override NoteHead #'font-series = #'bold
59 }
60
61 aikenHeads = \set shapeNoteStyles = ##(do re mi fa #f la ti)
62
63 sacredHarpHeads =
64   \set shapeNoteStyles = ##(fa #f la fa #f la mi)
65
66 dynamicUp = {
67   \override DynamicText  #'direction = #UP
68   \override DynamicLineSpanner  #'direction = #UP
69 }
70
71 dynamicDown = {
72   \override DynamicText  #'direction = #DOWN
73   \override DynamicLineSpanner  #'direction = #DOWN
74 }
75
76 dynamicNeutral = {
77   \revert DynamicText #'direction
78   \revert DynamicLineSpanner #'direction
79 }
80
81
82 dotsUp = \override Dots  #'direction = #UP
83 dotsDown = \override Dots  #'direction = #DOWN
84 dotsNeutral = \revert Dots #'direction 
85
86 tupletUp = \override TupletBracket  #'direction = #UP
87 tupletDown = \override TupletBracket  #'direction = #DOWN
88 tupletNeutral = \revert TupletBracket #'direction
89
90 cadenzaOn = \set Timing.timing = ##f
91 cadenzaOff = {
92   \set Timing.timing = ##t
93   \set Timing.measurePosition = #ZERO-MOMENT
94 }
95
96 % dynamic ly:dir?  text script, articulation script ly:dir?     
97 oneVoice = #(context-spec-music (make-voice-props-revert) 'Voice)
98 voiceOne = #(context-spec-music (make-voice-props-set 0) 'Voice)
99 voiceTwo = #(context-spec-music (make-voice-props-set 1) 'Voice)
100 voiceThree =#(context-spec-music (make-voice-props-set 2) 'Voice)
101 voiceFour = #(context-spec-music (make-voice-props-set 3) 'Voice)
102
103 voiceOneStyle = {
104   \override NoteHead #'style = #'diamond
105   \override NoteHead #'color = #red
106   \override Stem #'color = #red
107   \override Beam #'color = #red
108 }
109 voiceTwoStyle = {
110   \override NoteHead #'style = #'triangle
111   \override NoteHead #'color = #blue
112   \override Stem #'color = #blue
113   \override Beam #'color = #blue
114 }
115 voiceThreeStyle = {
116   \override NoteHead #'style = #'xcircle
117   \override NoteHead #'color = #green
118   \override Stem #'color = #green
119   \override Beam #'color = #green
120 }
121 voiceFourStyle = {
122   \override NoteHead #'style = #'cross
123   \override NoteHead #'color = #magenta
124   \override Stem #'color = #magenta
125   \override Beam #'color = #magenta
126 }
127 voiceNeutralStyle = {
128   \revert NoteHead #'style
129   \revert NoteHead #'color
130   \revert Stem #'color
131   \revert Beam #'color
132 }
133
134         
135 tiny = 
136 \set fontSize = #-2
137
138 small = 
139 \set fontSize = #-1
140
141 normalsize = {
142   \set fontSize = #0
143 }
144
145
146 %% End the incipit and print a ``normal line start''.
147 endincipit =  \context Staff {
148   \partial 16 s16  % Hack to handle e.g. \bar ".|" \endincipit
149   \once \override Staff.Clef  #'full-size-change = ##t
150   \once \override Staff.Clef  #'non-default = ##t
151   \bar ""
152 }
153
154 autoBeamOff = \set autoBeaming = ##f
155 autoBeamOn = \set autoBeaming = ##t
156
157 fatText = { \override TextScript  #'extra-spacing-width = #'(0 . 0)
158             \override TextScript  #'infinite-spacing-height = ##t }
159
160 emptyText = { \override TextScript  #'extra-spacing-width = #'(+inf.0 . -inf.0)
161               \override TextScript  #'infinite-spacing-height = ##f }
162
163 showStaffSwitch = \set followVoice = ##t
164 hideStaffSwitch = \set followVoice = ##f
165
166
167
168 % For drawing vertical chord brackets with \arpeggio
169 % This is a shorthand for the value of the print-function property 
170 % of either Staff.Arpeggio or PianoStaff.Arpeggio, depending whether 
171 % cross-staff brackets are desired. 
172
173 arpeggio = #(make-music 'ArpeggioEvent)
174
175 arpeggioUp = \sequential {
176   \revert Arpeggio  #'stencil
177   \override Arpeggio  #'arpeggio-direction = #UP
178 }
179 arpeggioDown = \sequential {
180   \revert Arpeggio #'stencil
181   \override Arpeggio  #'arpeggio-direction = #DOWN
182 }
183 arpeggioNeutral = \sequential {
184   \revert Arpeggio #'stencil
185   \revert Arpeggio  #'arpeggio-direction
186 }
187 arpeggioBracket = \sequential {
188   \override Arpeggio #'stencil = #ly:arpeggio::brew-chord-bracket
189 }
190
191 glissando = #(make-music 'GlissandoEvent)
192
193 fermataMarkup = \markup { \musicglyph #"scripts.ufermata" } 
194
195 hideNotes =\sequential {
196   % hide notes, accidentals, etc.
197   \override Dots  #'transparent = ##t
198   \override NoteHead  #'transparent = ##t
199   \override NoteHead  #'no-ledgers = ##t
200   \override Stem  #'transparent = ##t
201   \override Beam  #'transparent = ##t
202   \override Accidental  #'transparent = ##t
203 }
204
205
206 unHideNotes = \sequential {
207   \revert Accidental #'transparent
208   \revert Beam #'transparent
209   \revert Stem #'transparent
210   \revert NoteHead #'transparent
211   \revert NoteHead #'no-ledgers
212   \revert Dots #'transparent 
213 }
214
215 germanChords = {
216     \set chordRootNamer = #(chord-name->german-markup #t)
217     \set chordNoteNamer = #note-name->german-markup
218 }
219 semiGermanChords = {
220     \set chordRootNamer = #(chord-name->german-markup #f)
221     \set chordNoteNamer = #note-name->german-markup
222 }
223
224 frenchChords = {
225     \set chordRootNamer = #(chord-name->italian-markup #t)
226     \set chordPrefixSpacer = #0.4
227 }
228
229 italianChords = {
230     \set chordRootNamer = #(chord-name->italian-markup #f)
231     \set chordPrefixSpacer = #0.4
232 }
233
234 improvisationOn =  {
235     \set squashedPosition = #0
236     \override NoteHead  #'style = #'slash
237     \override Accidental #'stencil = ##f
238 }
239
240 improvisationOff =  {
241     \unset squashedPosition 
242     \revert NoteHead #'style
243     \revert Accidental #'stencil
244 }
245
246 textSpannerUp = \override TextSpanner #'direction = #UP
247 textSpannerDown = \override TextSpanner #'direction = #DOWN
248 textSpannerNeutral = \revert TextSpanner #'direction
249
250