]> git.donarmstrong.com Git - lilypond.git/blob - ly/declarations-init.ly
* lily/my-lily-parser.cc (ly:parser-add-book-and-score): New function.
[lilypond.git] / ly / declarations-init.ly
1 #(ly:set-option 'old-relative)
2
3 \version "2.2.0"
4 breve = #(ly:make-duration -1 0)
5 longa = #(ly:make-duration -2 0 )
6 maxima = #(ly:make-duration -3 0)
7
8 \include "nederlands.ly"                % dutch
9 \include "drumpitch-init.ly"            
10 \include "chord-modifiers-init.ly"
11 \include "script-init.ly"
12
13 % declarations for standard directions
14 left = -1
15 right = 1
16 up = 1
17 down = -1
18 start = -1
19 stop = 1
20 smaller = -1
21 bigger = 1
22 center=0
23
24 %{
25
26 should also set allowBeamBreak, but how to do it "portably"? (ie. also
27 working with lyric sections)
28
29 %}
30
31 %% rather name \newline, \newpage ?
32 break = #(make-event-chord (list (make-penalty-music -10001 0)))
33 noBreak = #(make-event-chord (list (make-penalty-music 10001 0)))
34 pagebreak = #(make-event-chord (list (make-penalty-music -10001 -10001)))
35 noPagebreak = #(make-event-chord (list (make-penalty-music 0 10001)))
36
37 noBeam = #(make-music 'BeamForbidEvent) 
38 pipeSymbol = #(make-music 'BarCheck)
39
40 \include "scale-definitions-init.ly"
41
42 melisma = #(make-span-event 'ManualMelismaEvent START)
43 melismaEnd = #(make-span-event 'ManualMelismaEvent STOP)
44
45 \include "grace-init.ly"
46
47 % ugh
48 \include "midi-init.ly"
49
50
51 % Do units first; must be done before any units are specified.
52 \paper {
53     unit = #(ly:unit)
54     mm = 1.0
55     in = 25.4
56     pt = #(/  in 72.27)
57     cm = #(* 10 mm)
58
59     inputencoding = #"TeX"
60     raggedright = ##f
61     raggedlast = ##f 
62     packed = ##f
63     
64     #(define $is-paper #t)
65     
66     #(define font-defaults
67       '((font-encoding . fetaMusic))
68       )
69
70     #(define text-font-defaults
71       '((font-encoding . latin1)
72         (baseline-skip . 2)
73         (word-space . 0.6)
74         ))
75
76     #(define page-breaking ly:ragged-page-breaks)
77     %%#(define page-breaking ly:optimal-page-breaks)
78
79     %% FIXME: too late?
80     #(define toplevel-music-handler ly:parser-add-book-and-score)
81     
82     \include "engraver-init.ly"
83 }
84
85 #(set-default-paper-size "a4")
86
87
88 %{
89
90 ; note:
91 ; you can add fonts manually  in the paper block by issuing
92
93 #(set! fonts (append ...myfonts... fonts))
94
95 for the format of myfonts, see font.scm
96
97 %}
98
99 paperEleven = \paper {
100     #(paper-set-staff-size (* 11.0 pt))
101 }
102
103 paperThirteen = \paper {
104     #(paper-set-staff-size (* 13.0 pt))
105 }
106
107 paperSixteen = \paper {
108     #(paper-set-staff-size (* 16.0 pt))
109 }
110
111 paperEightteen = \paper {
112     #(paper-set-staff-size (* 18.0 pt))
113 }
114
115 paperTwenty = \paper {
116     #(paper-set-staff-size (* 20.0 pt))
117 }
118
119 paperTwentythree = \paper {
120     #(paper-set-staff-size (* 23.0 pt))
121 }
122
123 paperTwentysix = \paper {
124     #(paper-set-staff-size (* 26.0 pt))
125 }
126
127 \paper { \paperTwenty }
128
129 partCombineListener = \paper {
130  \context {
131           \VoiceContext
132           \consists Note_heads_engraver
133           \consists Rest_engraver
134           \type "Recording_group_engraver"
135           recordEventSequence = #notice-the-events-for-pc
136  }
137  \context { \ScoreContext skipTypesetting = ##t }
138 }
139
140 #(set-part-combine-listener partCombineListener)
141
142 \include "dynamic-scripts-init.ly"
143 \include "spanners-init.ly"
144
145 \include "property-init.ly"
146
147
148
149 % reset default duration
150 unusedEntry = \notes { c4 }
151
152
153 % must have size argument for GUILE 1.6 compat.
154 #(define musicQuotes (make-hash-table 29))