1 %%%% This file is part of LilyPond, the GNU music typesetter.
3 %%%% Copyright (C) 1996--2010 Han-Wen Nienhuys <hanwen@xs4all.nl>
4 %%%% Jan Nieuwenhuizen <janneke@gnu.org>
6 %%%% LilyPond is free software: you can redistribute it and/or modify
7 %%%% it under the terms of the GNU General Public License as published by
8 %%%% the Free Software Foundation, either version 3 of the License, or
9 %%%% (at your option) any later version.
11 %%%% LilyPond is distributed in the hope that it will be useful,
12 %%%% but WITHOUT ANY WARRANTY; without even the implied warranty of
13 %%%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 %%%% GNU General Public License for more details.
16 %%%% You should have received a copy of the GNU General Public License
17 %%%% along with LilyPond. If not, see <http://www.gnu.org/licenses/>.
21 %% < 1.8 compatibility switch
22 #(ly
:set-option
'old-relative
)
25 breve
= #(ly
:make-duration -
1 0)
26 longa
= #(ly
:make-duration -
2 0)
27 maxima
= #(ly
:make-duration -
3 0)
29 \include "music-functions-init.ly"
30 \include "toc-init.ly"
32 %% default note names are dutch
33 \include "nederlands.ly"
35 \include "drumpitch-init.ly"
36 \include "chord-modifiers-init.ly"
37 \include "script-init.ly"
39 \include "chord-repetition-init.ly"
41 % declarations for standard directions
53 %% should also set \override Beam #'breakable, but how to do it "portably"? (ie. also
54 %% working with lyric sections)
56 %% try \once \override Score.Beam #'breakable = ##t
58 %% rather name \newline, \pageBreak ?
59 break
= #(make-event-chord
(list
(make-music
'LineBreakEvent
'break-permission
'force
)))
60 noBreak
= #(make-event-chord
(list
(make-music
'LineBreakEvent
'break-permission
'())))
61 %% \pageBreak, \noPageBreak, \pageTurn, \noPageTurn, \allowPageTurn are defined
64 stopStaff
= #(make-event-chord
(list
(make-span-event
'StaffSpanEvent STOP
)))
65 startStaff
= #(make-event-chord
(list
(make-span-event
'StaffSpanEvent START
)))
69 % Code articulation definitions
71 noBeam
= #(make-music
'BeamForbidEvent
)
72 pipeSymbol
= #(make-music
'BarCheck
)
73 bracketOpenSymbol
= #(make-span-event
'BeamEvent START
)
74 bracketCloseSymbol
= #(make-span-event
'BeamEvent STOP
)
75 tildeSymbol
= #(make-music
'TieEvent
)
76 parenthesisOpenSymbol
= #(make-span-event
'SlurEvent START
)
77 parenthesisCloseSymbol
= #(make-span-event
'SlurEvent STOP
)
78 escapedExclamationSymbol
= #(make-span-event
'CrescendoEvent STOP
)
79 escapedParenthesisOpenSymbol
= #(make-span-event
'PhrasingSlurEvent START
)
80 escapedParenthesisCloseSymbol
= #(make-span-event
'PhrasingSlurEvent STOP
)
81 escapedBiggerSymbol
= #(make-span-event
'DecrescendoEvent START
)
82 escapedSmallerSymbol
= #(make-span-event
'CrescendoEvent START
)
85 #(define fretboard-table
(make-hash-table
100))
86 #(define chord-shape-table
(make-hash-table
100))
88 \include "scale-definitions-init.ly"
90 melisma
= #(context-spec-music
(make-property-set
'melismaBusy
#t
) 'Bottom
)
91 melismaEnd
= #(context-spec-music
(make-property-unset
'melismaBusy
) 'Bottom
)
93 laissezVibrer
= #(make-music
'LaissezVibrerEvent
)
94 repeatTie
= #(make-music
'RepeatTieEvent
)
96 \include "grace-init.ly"
97 \include "midi-init.ly"
98 \include "paper-defaults-init.ly"
101 mm
= #(ly
:output-def-lookup $defaultpaper
'mm
)
102 unit
= #(ly
:output-def-lookup $defaultpaper
'unit
)
108 \include "engraver-init.ly"
110 #(set-paper-dimension-variables
(current-module
))
113 #(set-default-paper-size
(ly
:get-option
'paper-size
))
115 partCombineListener
= \layout {
118 skipTypesetting
= ##t
119 ignoreBarChecks
= ##t
124 \include "dynamic-scripts-init.ly"
125 \include "spanners-init.ly"
126 \include "property-init.ly"
128 setDefaultDurationToQuarter
= { c4 }
130 %% MAKE-HASH-TABLE in GUILE 1.6 takes mandatory size parameter.
131 #(define musicQuotes
(make-hash-table
29))
133 #(define toplevel-book-handler print-book-with-defaults
)
134 #(define toplevel-bookpart-handler collect-bookpart-for-book
)
135 #(define toplevel-music-handler collect-music-for-book
)
136 #(define toplevel-score-handler collect-scores-for-book
)
137 #(define toplevel-text-handler collect-scores-for-book
)
139 #(define book-bookpart-handler ly
:book-add-bookpart
!)
140 #(define book-music-handler collect-book-music-for-book
)
141 #(define book-score-handler ly
:book-add-score
!)
142 #(define book-text-handler ly
:book-add-score
!)
144 #(define bookpart-score-handler ly
:book-add-score
!)
145 #(define bookpart-text-handler ly
:book-add-score
!)
146 #(define bookpart-music-handler collect-book-music-for-book
)
148 \include "predefined-fretboards-init.ly"