Chordpro export
This commit is contained in:
@@ -158,6 +158,8 @@ override-stanza =
|
||||
#(define (stanza . stanzanumbers)
|
||||
#{
|
||||
\once \override StanzaNumber.details.custom-realstanza = ##t % set this to signal that there is a real stanza and no repeat signs
|
||||
\once \override StanzaNumber.details.custom-stanza-type = #'verse
|
||||
\once \override StanzaNumber.details.custom-stanza-numbers = #stanzanumbers
|
||||
\applyContext
|
||||
#(lambda (context)
|
||||
(handle-stanza-numbers context stanzanumbers
|
||||
@@ -169,6 +171,8 @@ ref =
|
||||
#(define-music-function (stanzanumbers lyrics) ((number-list? (list)) ly:music?)
|
||||
#{ \lyricmode {
|
||||
\once \override StanzaNumber.details.custom-realstanza = ##t % set this to signal that there is a real stanza and no repeat signs
|
||||
\once \override StanzaNumber.details.custom-stanza-type = #'ref
|
||||
\once \override StanzaNumber.details.custom-stanza-numbers = #stanzanumbers
|
||||
\applyContext
|
||||
#(lambda (context)
|
||||
(handle-stanza-numbers context stanzanumbers
|
||||
@@ -186,6 +190,8 @@ bridge =
|
||||
#(define-music-function (stanzanumbers lyrics) ((number-list? (list)) ly:music?)
|
||||
#{ \lyricmode {
|
||||
\once \override StanzaNumber.details.custom-realstanza = ##t % set this to signal that there is a real stanza and no repeat signs
|
||||
\once \override StanzaNumber.details.custom-stanza-type = #'bridge
|
||||
\once \override StanzaNumber.details.custom-stanza-numbers = #stanzanumbers
|
||||
\applyContext
|
||||
#(lambda (context)
|
||||
(handle-stanza-numbers context stanzanumbers
|
||||
@@ -201,8 +207,11 @@ bridge =
|
||||
|
||||
% prints a repStart Sign as stanza if the tag 'repeats is kept.
|
||||
% if there was a stanza already set by the stanza function with StanzaNumber.details.custom-realstanza = ##t we set that also as stanza.
|
||||
% Sets custom-inline-text for ChordPro export so it can collect the repeat sign separately
|
||||
repStartWithTag = \lyricmode {
|
||||
\tag #'repeats {
|
||||
\once \override StanzaNumber.details.custom-inline-text = \repStart
|
||||
\once \override StanzaNumber.details.custom-inline-direction = #LEFT
|
||||
\applyContext
|
||||
#(lambda (context)
|
||||
(let ((lastStanza (ly:context-property context 'stanza))
|
||||
@@ -220,6 +229,8 @@ repStartWithTag = \lyricmode {
|
||||
|
||||
repStopWithTag = \lyricmode {
|
||||
\tag #'repeats {
|
||||
\once \override StanzaNumber.details.custom-inline-text = \repStop
|
||||
\once \override StanzaNumber.details.custom-inline-direction = #RIGHT
|
||||
\once \override StanzaNumber.font-series = #'normal
|
||||
\once \override StanzaNumber.direction = 1
|
||||
\set stanza = \markup { \pad-x-right #1 \repStop }
|
||||
|
||||
Reference in New Issue
Block a user