]> git.donarmstrong.com Git - lilypond.git/blob - ly/property-init.ly
Merge branch 'master' of ssh://jomand@git.sv.gnu.org/srv/git/lilypond into dev/jmandereau
[lilypond.git] / ly / property-init.ly
1 % property-init.ly
2
3 \version "2.11.38"
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 easyHeadsOn = {
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 easyHeadsOff = {
62   \revert NoteHead #'stencil
63   \revert NoteHead #'font-size
64   \revert NoteHead #'font-family
65   \revert NoteHead #'font-series
66 }
67
68 aikenHeads = \set shapeNoteStyles = ##(do re mi fa #f la ti)
69
70 sacredHarpHeads =
71   \set shapeNoteStyles = ##(fa #f la fa #f la mi)
72
73 dynamicUp = {
74   \override DynamicText  #'direction = #UP
75   \override DynamicLineSpanner  #'direction = #UP
76 }
77
78 dynamicDown = {
79   \override DynamicText  #'direction = #DOWN
80   \override DynamicLineSpanner  #'direction = #DOWN
81 }
82
83 dynamicNeutral = {
84   \revert DynamicText #'direction
85   \revert DynamicLineSpanner #'direction
86 }
87
88
89 dotsUp = \override Dots  #'direction = #UP
90 dotsDown = \override Dots  #'direction = #DOWN
91 dotsNeutral = \revert Dots #'direction 
92
93 tupletUp = \override TupletBracket  #'direction = #UP
94 tupletDown = \override TupletBracket  #'direction = #DOWN
95 tupletNeutral = \revert TupletBracket #'direction
96
97 cadenzaOn = \set Timing.timing = ##f
98 cadenzaOff = {
99   \set Timing.timing = ##t
100   \set Timing.measurePosition = #ZERO-MOMENT
101 }
102
103 % dynamic ly:dir?  text script, articulation script ly:dir?     
104 oneVoice = #(context-spec-music (make-voice-props-revert) 'Voice)
105 voiceOne = #(context-spec-music (make-voice-props-set 0) 'Voice)
106 voiceTwo = #(context-spec-music (make-voice-props-set 1) 'Voice)
107 voiceThree =#(context-spec-music (make-voice-props-set 2) 'Voice)
108 voiceFour = #(context-spec-music (make-voice-props-set 3) 'Voice)
109
110 voiceOneStyle = {
111   \override NoteHead #'style = #'diamond
112   \override NoteHead #'color = #red
113   \override Stem #'color = #red
114   \override Beam #'color = #red
115 }
116 voiceTwoStyle = {
117   \override NoteHead #'style = #'triangle
118   \override NoteHead #'color = #blue
119   \override Stem #'color = #blue
120   \override Beam #'color = #blue
121 }
122 voiceThreeStyle = {
123   \override NoteHead #'style = #'xcircle
124   \override NoteHead #'color = #green
125   \override Stem #'color = #green
126   \override Beam #'color = #green
127 }
128 voiceFourStyle = {
129   \override NoteHead #'style = #'cross
130   \override NoteHead #'color = #magenta
131   \override Stem #'color = #magenta
132   \override Beam #'color = #magenta
133 }
134 voiceNeutralStyle = {
135   \revert NoteHead #'style
136   \revert NoteHead #'color
137   \revert Stem #'color
138   \revert Beam #'color
139 }
140
141         
142 tiny = 
143 \set fontSize = #-2
144
145 small = 
146 \set fontSize = #-1
147
148 normalsize = {
149   \set fontSize = #0
150 }
151
152
153 %% End the incipit and print a ``normal line start''.
154 endincipit =  \context Staff {
155   \partial 16 s16  % Hack to handle e.g. \bar ".|" \endincipit
156   \once \override Staff.Clef  #'full-size-change = ##t
157   \once \override Staff.Clef  #'non-default = ##t
158   \bar ""
159 }
160
161 autoBeamOff = \set autoBeaming = ##f
162 autoBeamOn = \set autoBeaming = ##t
163
164 textLengthOn = {
165   \override TextScript  #'extra-spacing-width = #'(0 . 0)
166   \override TextScript  #'infinite-spacing-height = ##t
167 }
168
169 textLengthOff = {
170   \override TextScript  #'extra-spacing-width = #'(+inf.0 . -inf.0)
171   \override TextScript  #'infinite-spacing-height = ##f
172 }
173
174 showStaffSwitch = \set followVoice = ##t
175 hideStaffSwitch = \set followVoice = ##f
176
177
178
179 % For drawing vertical chord brackets with \arpeggio
180 % This is a shorthand for the value of the print-function property 
181 % of either Staff.Arpeggio or PianoStaff.Arpeggio, depending whether 
182 % cross-staff brackets are desired. 
183
184 arpeggio = #(make-music 'ArpeggioEvent)
185
186 arpeggioUp = \sequential {
187   \revert Arpeggio  #'stencil
188   \override Arpeggio  #'arpeggio-direction = #UP
189 }
190 arpeggioDown = \sequential {
191   \revert Arpeggio #'stencil
192   \override Arpeggio  #'arpeggio-direction = #DOWN
193 }
194 arpeggioNeutral = \sequential {
195   \revert Arpeggio #'stencil
196   \revert Arpeggio  #'arpeggio-direction
197 }
198 arpeggioBracket = \sequential {
199   \override Arpeggio #'stencil = #ly:arpeggio::brew-chord-bracket
200 }
201
202 glissando = #(make-music 'GlissandoEvent)
203
204 fermataMarkup = \markup { \musicglyph #"scripts.ufermata" } 
205
206 hideNotes =\sequential {
207   % hide notes, accidentals, etc.
208   \override Dots  #'transparent = ##t
209   \override NoteHead  #'transparent = ##t
210   \override NoteHead  #'no-ledgers = ##t
211   \override Stem  #'transparent = ##t
212   \override Beam  #'transparent = ##t
213   \override Accidental  #'transparent = ##t
214 }
215
216
217 unHideNotes = \sequential {
218   \revert Accidental #'transparent
219   \revert Beam #'transparent
220   \revert Stem #'transparent
221   \revert NoteHead #'transparent
222   \revert NoteHead #'no-ledgers
223   \revert Dots #'transparent 
224 }
225
226 germanChords = {
227     \set chordRootNamer = #(chord-name->german-markup #t)
228     \set chordNoteNamer = #note-name->german-markup
229 }
230 semiGermanChords = {
231     \set chordRootNamer = #(chord-name->german-markup #f)
232     \set chordNoteNamer = #note-name->german-markup
233 }
234
235 frenchChords = {
236     \set chordRootNamer = #(chord-name->italian-markup #t)
237     \set chordPrefixSpacer = #0.4
238 }
239
240 italianChords = {
241     \set chordRootNamer = #(chord-name->italian-markup #f)
242     \set chordPrefixSpacer = #0.4
243 }
244
245 improvisationOn =  {
246     \set squashedPosition = #0
247     \override NoteHead  #'style = #'slash
248     \override Accidental #'stencil = ##f
249 }
250
251 improvisationOff =  {
252     \unset squashedPosition 
253     \revert NoteHead #'style
254     \revert Accidental #'stencil
255 }
256
257 textSpannerUp = \override TextSpanner #'direction = #UP
258 textSpannerDown = \override TextSpanner #'direction = #DOWN
259 textSpannerNeutral = \revert TextSpanner #'direction
260
261