My piece involves a D.S. al coda repeat across a key signature change, like:
\mark \markup { \musicglyph #"scripts.segno" }
\key a \minor
a b c' d'
% more music in a minor
\key a \major
a b cis' d'
% more music in a major
\once \override Score.RehearsalMark #'break-visibility = #end-of-line-visible
\once \override Score.RehearsalMark #'self-alignment-X = #RIGHT
\mark "D.S. al coda"
\bar "||"
% coda in a major follows
To help the player make the transition back from a major to a minor at the dal segno I'd like to print a key cancellation just before the double bar. The bars of the coda that follows, should remain in a major.
How would I accomplish that in Lilypond 2.14 or higher?
Append to your code