transposeGlobal kann ganzen Song transponieren
This commit is contained in:
parent
8e6eff1cad
commit
19b5fe2d94
@ -12,9 +12,11 @@
|
|||||||
\include "footer_with_songinfo.ly"
|
\include "footer_with_songinfo.ly"
|
||||||
\include "auto_rest_merging.ly"
|
\include "auto_rest_merging.ly"
|
||||||
\include "chord_settings.ly"
|
\include "chord_settings.ly"
|
||||||
|
\include "transposition.ly"
|
||||||
\include "verses_with_chords.ly"
|
\include "verses_with_chords.ly"
|
||||||
\include "arrows_in_scores.ly"
|
\include "arrows_in_scores.ly"
|
||||||
\include "swing_style.ly"
|
\include "swing_style.ly"
|
||||||
|
\include "inline_score.ly"
|
||||||
|
|
||||||
% reset important variables
|
% reset important variables
|
||||||
LAYOUT = \layout { \generalLayout }
|
LAYOUT = \layout { \generalLayout }
|
||||||
|
5
inline_score.ly
Normal file
5
inline_score.ly
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
inline-score =
|
||||||
|
#(define-music-function (music) (ly:music?)
|
||||||
|
#{
|
||||||
|
\transposable #music
|
||||||
|
#})
|
@ -1,6 +1,8 @@
|
|||||||
% set the speed of the midi music
|
% set the speed of the midi music
|
||||||
#(define midiQuarterNoteSpeed (if (defined? 'midiQuarterNoteSpeed) midiQuarterNoteSpeed 90))
|
#(define midiQuarterNoteSpeed (if (defined? 'midiQuarterNoteSpeed) midiQuarterNoteSpeed 90))
|
||||||
|
|
||||||
|
MUSIC = { \transposable \MUSIC }
|
||||||
|
|
||||||
% nur Output wenn noStandaloneOutput auf false steht
|
% nur Output wenn noStandaloneOutput auf false steht
|
||||||
output = #(if (not noStandaloneOutput)
|
output = #(if (not noStandaloneOutput)
|
||||||
#{
|
#{
|
||||||
|
13
transposition.ly
Normal file
13
transposition.ly
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
TRANSPOSITION = ##f
|
||||||
|
|
||||||
|
transposeGlobal =
|
||||||
|
#(define-void-function (from to) (ly:pitch? ly:pitch?)
|
||||||
|
(set! TRANSPOSITION (cons from to)))
|
||||||
|
|
||||||
|
transposable =
|
||||||
|
#(define-music-function (music) (ly:music?)
|
||||||
|
(if TRANSPOSITION
|
||||||
|
#{
|
||||||
|
\transpose #(car TRANSPOSITION) #(cdr TRANSPOSITION) #music
|
||||||
|
#}
|
||||||
|
music))
|
@ -119,7 +119,7 @@
|
|||||||
(regexp-substitute/global #f "\\(( *)([^,()]*)( *),([^)]*)\\)"
|
(regexp-substitute/global #f "\\(( *)([^,()]*)( *),([^)]*)\\)"
|
||||||
(regexp-substitute/global #f "(([^ \n]*\\([^()]*\\)[^ \n]*)+)" verse
|
(regexp-substitute/global #f "(([^ \n]*\\([^()]*\\)[^ \n]*)+)" verse
|
||||||
'pre " \\concat { " 1 " } " 'post)
|
'pre " \\concat { " 1 " } " 'post)
|
||||||
'pre "\\textup \\line { \"" 1 "\" " 2 " \"" 3 "\" } \\score { " transp " \\chords { s4 " 4 " } \\layout { \\verseChordLayout } }" 'post))
|
'pre "\\textup \\line { \"" 1 "\" " 2 " \"" 3 "\" } \\score { \\transposable " transp " \\chords { s4 " 4 " } \\layout { \\verseChordLayout } }" 'post))
|
||||||
))))
|
))))
|
||||||
|
|
||||||
% Kompletter Vers aus dem Akkorde entfernt werden
|
% Kompletter Vers aus dem Akkorde entfernt werden
|
||||||
|
Loading…
Reference in New Issue
Block a user