Compare commits
No commits in common. "main" and "chordExceptions" have entirely different histories.
main
...
chordExcep
@ -29,14 +29,12 @@
|
||||
\include "swing_style.ly"
|
||||
\include "inline_score.ly"
|
||||
\include "custom_indentation.ily"
|
||||
\include "include_from_song.ily"
|
||||
|
||||
% reset important variables
|
||||
LAYOUT = \layout { \generalLayout }
|
||||
HEADER = {}
|
||||
MUSIC = {}
|
||||
TEXT = \markuplist {}
|
||||
TEXT_PAGES = #f
|
||||
TEXT = \markuplist {""}
|
||||
|
||||
verseChords = {}
|
||||
firstVoice = {}
|
||||
|
@ -225,9 +225,9 @@ cue =
|
||||
#{
|
||||
\tag #'cues {
|
||||
\tweak self-alignment-X #LEFT
|
||||
\mark
|
||||
\mark
|
||||
#(make-on-the-fly-markup
|
||||
(lambda (layout props m) (interpret-markup layout (prepend-alist-chain 'cues zahlen props) (ly:output-def-lookup layout 'cueMarkup)))
|
||||
(make-null-markup))
|
||||
}
|
||||
#})
|
||||
#})
|
@ -114,7 +114,7 @@ width may require additional tweaking.)"
|
||||
|
||||
|
||||
includeSong =
|
||||
#(define-void-function (parser location filename) (string?)
|
||||
#(define-void-function (parser location textproc filename) ((procedure?) string?)
|
||||
#{
|
||||
\bookOutputName #filename
|
||||
#}
|
||||
@ -125,15 +125,7 @@ includeSong =
|
||||
(acons label additional-page-numbers additional-page-switch-label-list))
|
||||
(set! song-list
|
||||
(acons (string->symbol filename)
|
||||
(acons 'label label
|
||||
(acons 'header HEADER
|
||||
(acons 'music MUSIC
|
||||
(acons 'layout LAYOUT
|
||||
(acons 'text-pages
|
||||
(map (lambda (text)
|
||||
#{ \markuplist \setsongfilename $filename $text #})
|
||||
TEXT_PAGES)
|
||||
'())))))
|
||||
(acons 'label label (acons 'header HEADER (acons 'music MUSIC (acons 'layout LAYOUT (acons 'text #{ \markuplist \setsongfilename $filename $(if textproc (textproc TEXT) TEXT) #} '())))))
|
||||
song-list))
|
||||
))
|
||||
|
||||
@ -192,14 +184,14 @@ songs =
|
||||
;(header (assq-ref songvars 'header))
|
||||
(music (assq-ref songvars 'music))
|
||||
(layout (assq-ref songvars 'layout))
|
||||
(text-pages (assq-ref songvars 'text-pages))
|
||||
(text (assq-ref songvars 'text))
|
||||
(label (assq-ref songvars 'label)))
|
||||
#{
|
||||
\bookpart {
|
||||
$header
|
||||
\headerToTOC #header #label
|
||||
\score { $music \layout { $layout } }
|
||||
$(add-text-pages text-pages)
|
||||
$text
|
||||
}
|
||||
#}))))))
|
||||
(reverse song-list)
|
||||
|
@ -68,18 +68,6 @@ altChord =
|
||||
#mainchord
|
||||
#}))
|
||||
|
||||
% Akkorde werden so transponiert, dass sie passen, wenn man mit Kapo im angegebenen Bund spielt
|
||||
capoTranspose =
|
||||
#(define-music-function (fret chords) (number? ly:music?)
|
||||
(define semi->pitch
|
||||
(make-semitone->pitch
|
||||
(music-pitches
|
||||
#{ h b a gis g fis f e es d cis c #})))
|
||||
(transpose
|
||||
(ly:pitch-transpose (semi->pitch fret) (ly:make-pitch 0 0))
|
||||
(ly:make-pitch 0 0)
|
||||
chords))
|
||||
|
||||
% kleine Mollakkorde und Alteration ausgeschrieben
|
||||
#(define (note-name->german-markup-nosym pitch lowercase?)
|
||||
(define (pitch-alteration-semitones pitch) (inexact->exact (round (* (ly:pitch-alteration pitch) 2))))
|
||||
|
@ -1,7 +0,0 @@
|
||||
includeFromSong =
|
||||
#(define-void-function (filename) (string?)
|
||||
(let ((noDefaultOutputBackup noDefaultOutput))
|
||||
(set! noDefaultOutput #t)
|
||||
(ly:parser-parse-string (ly:parser-clone)
|
||||
(ly:format "\\include \"~a\"" filename))
|
||||
(set! noDefaultOutput noDefaultOutputBackup)))
|
@ -26,34 +26,6 @@ TEXT = \markuplist {
|
||||
\TEXT
|
||||
}
|
||||
|
||||
#(define TEXT_PAGES
|
||||
(map
|
||||
(lambda (text) #{
|
||||
\markuplist {
|
||||
\override #`(transposition . ,TRANSPOSITION)
|
||||
\override #`(verselayout . ,verselayout)
|
||||
\override #`(verse-chords . ,#{ \chords { \verseChords } #})
|
||||
\override #`(verse-reference-voice . ,#{ \global \firstVoice #})
|
||||
#text
|
||||
}
|
||||
#})
|
||||
(if
|
||||
(and
|
||||
(defined? 'TEXT_PAGES)
|
||||
(pair? TEXT_PAGES))
|
||||
TEXT_PAGES
|
||||
(list TEXT))))
|
||||
|
||||
#(define (add-text-pages text-pages)
|
||||
(if (pair? text-pages)
|
||||
(begin
|
||||
(add-score (car text-pages))
|
||||
(for-each
|
||||
(lambda (text)
|
||||
(add-music (pageBreak))
|
||||
(add-score text))
|
||||
(cdr text-pages)))))
|
||||
|
||||
#(if (not noStandaloneOutput)
|
||||
(begin
|
||||
(let ((header (ly:book-header HEADER)) (paper (ly:book-paper HEADER)))
|
||||
@ -65,7 +37,7 @@ TEXT = \markuplist {
|
||||
\MUSIC
|
||||
\layout { \LAYOUT }
|
||||
}#})
|
||||
(add-text-pages TEXT_PAGES)
|
||||
(add-score TEXT)
|
||||
(add-score #{
|
||||
\score {
|
||||
\unfoldRepeats { \MUSIC \INLINESCOREMUSIC }
|
||||
|
@ -221,28 +221,14 @@
|
||||
(cons (car x) (+ (cdr x) amount))
|
||||
y)))
|
||||
|
||||
#(define-markup-command (score-equal-height-with-indents layout props lines)
|
||||
(markup-list?)
|
||||
#(define-markup-command (score-equal-height layout props reference-height lines)
|
||||
(number? markup-list?)
|
||||
#:category music
|
||||
#:properties ((intraverse-vspace 0)
|
||||
(verse-line-height songTextLineHeigth)
|
||||
(line-indents '()))
|
||||
(let ((indents-max-index (- (length line-indents) 1)))
|
||||
(stack-stencils Y DOWN intraverse-vspace
|
||||
(index-map
|
||||
(lambda (index line)
|
||||
(let ((stil
|
||||
(ly:make-stencil
|
||||
(ly:stencil-expr line)
|
||||
(ly:stencil-extent line X)
|
||||
`(,(/ verse-line-height -2.0) . ,(/ verse-line-height 2.0)))))
|
||||
(if (<= index indents-max-index)
|
||||
(ly:stencil-translate-axis
|
||||
stil
|
||||
(list-ref line-indents index)
|
||||
X)
|
||||
stil)))
|
||||
(interpret-markup-list layout props lines)))))
|
||||
#:properties ((baseline-skip))
|
||||
(stack-stencils Y DOWN baseline-skip
|
||||
(map
|
||||
(lambda (line) (ly:make-stencil (ly:stencil-expr line) (ly:stencil-extent line X) `(,(/ reference-height -2.0) . ,(/ reference-height 2.0))))
|
||||
(interpret-markup-list layout props lines))))
|
||||
|
||||
#(define-public (custom-lyric-text::print grob)
|
||||
"Allow interpretation of tildes as lyric tieing marks."
|
||||
@ -257,17 +243,20 @@
|
||||
#:properties ((verse-chords #{#})
|
||||
(verse-reference-voice #{#})
|
||||
(verse-break-voice #{#})
|
||||
(verse-line-height songTextLineHeigth)
|
||||
(verse-text-chord-distance songTextChordDistance)
|
||||
(intraverse-vspace 0)
|
||||
(transposition (cons #f #f))
|
||||
(verselayout generalLayout))
|
||||
"Vers mit Akkorden"
|
||||
(interpret-markup layout props
|
||||
#{
|
||||
\markup {
|
||||
\score-equal-height-with-indents \score-lines {
|
||||
\override #`(baseline-skip . ,intraverse-vspace)
|
||||
\score-equal-height #verse-line-height \score-lines {
|
||||
<<
|
||||
\new Devnull { #(music-clone verse-break-voice) }
|
||||
\new NullVoice = "dummyvoice" { #(music-clone verse-reference-voice) }
|
||||
\new Devnull { #verse-break-voice }
|
||||
\new NullVoice = "dummyvoice" { #verse-reference-voice }
|
||||
\transposable #transposition #(music-clone verse-chords)
|
||||
\new Lyrics \lyricsto "dummyvoice" { #lyrics }
|
||||
>>
|
||||
@ -303,7 +292,6 @@
|
||||
\remove Jump_engraver
|
||||
\remove Volta_engraver
|
||||
\remove Parenthesis_engraver
|
||||
\remove Metronome_mark_engraver
|
||||
}
|
||||
\context {
|
||||
\Staff
|
||||
@ -330,9 +318,8 @@
|
||||
\NullVoice
|
||||
\consists Rest_engraver
|
||||
\omit Rest
|
||||
\undo \omit NoteHead
|
||||
\hide NoteHead
|
||||
\override NoteHead.X-extent = #'(0 . 0)
|
||||
% \undo \omit NoteHead
|
||||
% \hide NoteHead
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user