]> git.donarmstrong.com Git - lilypond.git/blob - ly/declarations-init.ly
Merge with master
[lilypond.git] / ly / declarations-init.ly
1 \version "2.10.0"
2
3 %% < 1.8 compatibility switch
4 #(ly:set-option 'old-relative)
5
6 %% named durations
7 breve = #(ly:make-duration -1 0)
8 longa = #(ly:make-duration -2 0)
9 maxima = #(ly:make-duration -3 0)
10
11 \include "markup-init.ly"
12 \include "music-functions-init.ly"
13
14 %% default note names are dutch
15 \include "nederlands.ly"
16
17 \include "drumpitch-init.ly"            
18 \include "chord-modifiers-init.ly"
19 \include "script-init.ly"
20
21 % declarations for standard directions
22 left = #-1
23 right = #1
24 up = #1
25 down = #-1
26 start = #-1
27 stop = #1
28 smaller = #-1
29 bigger = #1
30 center = #0
31
32 %% FIXME
33 %% should also set allowBeamBreak, but how to do it "portably"? (ie. also
34 %% working with lyric sections)
35 %%
36 %% try \once \set Score.allowBeamBreak = ##t
37
38 %% rather name \newline, \pageBreak ?
39 break = #(make-event-chord (list (make-music 'LineBreakEvent 'break-permission 'force)))
40 noBreak = #(make-event-chord (list (make-music 'LineBreakEvent 'break-permission '())))
41 pageBreak = #(make-event-chord (list
42                                 (make-music 'LineBreakEvent 'break-permission 'force)
43                                 (make-music 'PageBreakEvent 'break-permission 'force)))
44 noPageBreak = #(make-event-chord (list (make-music 'PageBreakEvent 'break-permission '())))
45 pageTurn = #(make-event-chord (list
46                                 (make-music 'LineBreakEvent 'break-permission 'force)
47                                 (make-music 'PageBreakEvent 'break-permission 'force)
48                                 (make-music 'PageTurnEvent 'break-permission 'force)))
49 noPageTurn = #(make-event-chord (list (make-music 'PageTurnEvent 'break-permission '())))
50 allowPageTurn = #(make-event-chord (list (make-music 'PageTurnEvent 'break-permission 'allow)))
51
52 stopStaff = #(make-event-chord (list (make-span-event 'StaffSpanEvent STOP)))
53 startStaff = #(make-event-chord (list (make-span-event 'StaffSpanEvent START)))
54
55
56 %
57 % Code articulation definitions
58 %
59 noBeam = #(make-music 'BeamForbidEvent) 
60 pipeSymbol = #(make-music 'BarCheck)
61 bracketOpenSymbol = #(make-span-event 'BeamEvent START)
62 bracketCloseSymbol = #(make-span-event 'BeamEvent STOP)
63 tildeSymbol = #(make-music 'TieEvent)
64 parenthesisOpenSymbol =  #(make-span-event 'SlurEvent START)
65 parenthesisCloseSymbol = #(make-span-event 'SlurEvent STOP)
66 escapedExclamationSymbol = #(make-span-event 'CrescendoEvent STOP)
67 escapedParenthesisOpenSymbol = #(make-span-event 'PhrasingSlurEvent START)
68 escapedParenthesisCloseSymbol = #(make-span-event 'PhrasingSlurEvent STOP)
69 escapedBiggerSymbol = #(make-span-event 'DecrescendoEvent START)
70 escapedSmallerSymbol = #(make-span-event 'CrescendoEvent START)
71
72
73
74 \include "scale-definitions-init.ly"
75
76 melisma = #(context-spec-music (make-property-set 'melismaBusy #t) 'Bottom)
77 melismaEnd = #(context-spec-music (make-property-unset 'melismaBusy) 'Bottom)
78
79 laissezVibrer = #(make-music 'LaissezVibrerEvent)
80 repeatTie = #(make-music 'RepeatTieEvent)
81                   
82 \include "grace-init.ly"
83 \include "midi-init.ly"
84 \include "paper-defaults.ly"
85
86 \layout {
87     mm = #(ly:output-def-lookup $defaultpaper 'mm)
88     unit = #(ly:output-def-lookup $defaultpaper 'unit)
89
90     in = #(* 25.4 mm)
91     pt = #(/  in 72.27)
92     cm = #(* 10 mm)
93     
94     \include "engraver-init.ly"
95
96     #(set-paper-dimension-variables (current-module))
97 }
98
99 #(set-default-paper-size (ly:get-option 'paper-size))
100
101 partCombineListener = \layout {
102     \context {
103         \Score
104         skipTypesetting = ##t
105         ignoreBarChecks = ##t
106         \alias "Timing"
107     }
108 }
109
110 \include "dynamic-scripts-init.ly"
111 \include "spanners-init.ly"
112 \include "property-init.ly"
113
114 setDefaultDurationToQuarter = { c4 }
115
116 %% MAKE-HASH-TABLE in GUILE 1.6 takes mandatory size parameter.
117 #(define musicQuotes (make-hash-table 29))
118
119 #(define toplevel-book-handler print-book-with-defaults)
120 #(define toplevel-music-handler collect-music-for-book)
121 #(define toplevel-score-handler collect-scores-for-book)
122 #(define toplevel-text-handler collect-scores-for-book)
123