X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=ly%2Fdeclarations-init.ly;h=3ff8e221197c57d83c47998649e2503e9444c157;hb=becfb1f1b2bcc675fc65cafd26002fb5eaf2d88f;hp=6293006cac111cfa11c09c18782d7ef73ee0bc43;hpb=92125c0a3d8ab85e060dcb0faba2c8b2ba73859a;p=lilypond.git diff --git a/ly/declarations-init.ly b/ly/declarations-init.ly index 6293006cac..3ff8e22119 100644 --- a/ly/declarations-init.ly +++ b/ly/declarations-init.ly @@ -1,138 +1,122 @@ +\version "2.7.39" + +%% < 1.8 compatibility switch #(ly:set-option 'old-relative) -\version "2.1.30" +%% named durations breve = #(ly:make-duration -1 0) -longa = #(ly:make-duration -2 0 ) +longa = #(ly:make-duration -2 0) maxima = #(ly:make-duration -3 0) -\include "nederlands.ly" % dutch +\include "music-functions-init.ly" + +%% default note names are dutch +\include "nederlands.ly" + \include "drumpitch-init.ly" \include "chord-modifiers-init.ly" \include "script-init.ly" % declarations for standard directions -left = -1 -right = 1 -up = 1 -down = -1 -start = -1 -stop = 1 -smaller = -1 -bigger = 1 -center=0 - -%{ - -should also set allowBeamBreak, but how to do it "portably"? (ie. also -working with lyric sections) +left = #-1 +right = #1 +up = #1 +down = #-1 +start = #-1 +stop = #1 +smaller = #-1 +bigger = #1 +center = #0 + +%% FIXME +%% should also set allowBeamBreak, but how to do it "portably"? (ie. also +%% working with lyric sections) +%% +%% try \once \set Score.allowBeamBreak = ##t + +%% rather name \newline, \pageBreak ? +break = #(make-event-chord (list (make-music 'LineBreakEvent 'break-permission 'force))) +noBreak = #(make-event-chord (list (make-music 'LineBreakEvent 'break-permission '()))) +pageBreak = #(make-event-chord (list + (make-music 'LineBreakEvent 'break-permission 'force) + (make-music 'PageBreakEvent 'break-permission 'force))) +noPageBreak = #(make-event-chord (list (make-music 'PageBreakEvent 'break-permission '()))) +pageTurn = #(make-event-chord (list + (make-music 'LineBreakEvent 'break-permission 'force) + (make-music 'PageBreakEvent 'break-permission 'force) + (make-music 'PageTurnEvent 'break-permission 'force))) +noPageTurn = #(make-event-chord (list (make-music 'PageTurnEvent 'break-permission '()))) +allowPageTurn = #(make-event-chord (list (make-music 'PageTurnEvent 'break-permission 'allow))) + +stopStaff = #(make-event-chord (list (make-span-event 'StaffSpanEvent STOP))) +startStaff = #(make-event-chord (list (make-span-event 'StaffSpanEvent START))) + + +% +% Code articulation definitions +% +noBeam = #(make-music 'BeamForbidEvent) +pipeSymbol = #(make-music 'BarCheck) +bracketOpenSymbol = #(make-span-event 'BeamEvent START) +bracketCloseSymbol = #(make-span-event 'BeamEvent STOP) +tildeSymbol = #(make-music 'TieEvent) +parenthesisOpenSymbol = #(make-span-event 'SlurEvent START) +parenthesisCloseSymbol = #(make-span-event 'SlurEvent STOP) +escapedExclamationSymbol = #(make-span-event 'CrescendoEvent STOP) +escapedParenthesisOpenSymbol = #(make-span-event 'PhrasingSlurEvent START) +escapedParenthesisCloseSymbol = #(make-span-event 'PhrasingSlurEvent STOP) +escapedBiggerSymbol = #(make-span-event 'DecrescendoEvent START) +escapedSmallerSymbol = #(make-span-event 'CrescendoEvent START) -%} -break =#(make-event-chord (list (make-penalty-music -10001))) -noBreak = #(make-event-chord (list (make-penalty-music 10001))) -noBeam = #(make-music 'BeamForbidEvent) \include "scale-definitions-init.ly" -melisma = #(make-span-event 'ManualMelismaEvent START) -melismaEnd = #(make-span-event 'ManualMelismaEvent STOP) +melisma = #(context-spec-music (make-property-set 'melismaBusy #t) 'Bottom) +melismaEnd = #(context-spec-music (make-property-unset 'melismaBusy) 'Bottom) +laissezVibrer = #(make-music 'LaissezVibrerEvent) +repeatTie = #(make-music 'RepeatTieEvent) + \include "grace-init.ly" - -% ugh \include "midi-init.ly" +\include "paper-defaults.ly" +\layout { + mm = #(ly:output-def-lookup $defaultpaper 'mm) + unit = #(ly:output-def-lookup $defaultpaper 'unit) -% Do units first; must be done before any units are specified. -\paper { - unit = #(ly:unit) - mm = 1.0 - in = 25.4 + in = #(* 25.4 mm) pt = #(/ in 72.27) cm = #(* 10 mm) - - #(define font-defaults - '((font-encoding . music)) - ) - - #(define text-font-defaults - '((font-encoding . text) - (baseline-skip . 2) - (word-space . 0.6) - )) - \include "engraver-init.ly" -} - -#(set-paper-size "a4") - - -%{ - -; note: -; you can add fonts manually in the paper block by issuing - -#(set! fonts (append ...myfonts... fonts)) -for the format of myfonts, see font.scm - -%} - - -paperEleven = \paper { - #(paper-set-staff-size (* 11.0 pt)) + #(set-paper-dimension-variables (current-module)) } -paperThirteen = \paper { - #(paper-set-staff-size (* 13.0 pt)) -} +#(set-default-paper-size (ly:get-option 'paper-size)) -paperSixteen = \paper { - #(paper-set-staff-size (* 16.0 pt)) +partCombineListener = \layout { + \context { + \Score + skipTypesetting = ##t + ignoreBarChecks = ##t + \alias "Timing" + } } -paperEightteen = \paper { - #(paper-set-staff-size (* 18.0 pt)) -} - -paperTwenty = \paper { - #(paper-set-staff-size (* 20.0 pt)) -} - -paperTwentythree = \paper { - #(paper-set-staff-size (* 23.0 pt)) -} - -paperTwentysix = \paper { - #(paper-set-staff-size (* 26.0 pt)) -} - -\paper { \paperTwenty } - -partCombineListener = \paper { - \context { - \VoiceContext - \consists Note_heads_engraver - \consists Rest_engraver - \type "Recording_group_engraver" - recordEventSequence = #notice-the-events-for-pc - } - \context { \ScoreContext skipTypesetting = ##t } -} - -#(set-part-combine-listener partCombineListener) - \include "dynamic-scripts-init.ly" \include "spanners-init.ly" - \include "property-init.ly" +setDefaultDurationToQuarter = { c4 } +%% MAKE-HASH-TABLE in GUILE 1.6 takes mandatory size parameter. +#(define musicQuotes (make-hash-table 29)) -% reset default duration -unusedEntry = \notes { c4 } - +#(define toplevel-book-handler print-book-with-defaults) +#(define toplevel-music-handler collect-music-for-book) +#(define toplevel-score-handler collect-scores-for-book) +#(define toplevel-text-handler collect-scores-for-book) -% must have size argument for GUILE 1.6 compat. -#(define musicQuotes (make-hash-table 29))