Le 01/03/2022 à 23:51, Alasdair a écrit :

Dear Jean,

I have just had time to make that change (of key to key-signature).  However, there is still an issue.  For example, in change from g major to g minor, we go from one sharp to two flats.  As I have a key signature in the middle of a bar (after a “Fine”), my current bar looks like this:

g4^\markup \fontsize #2 \italic "Fin" \bar "||" \set Staff.forceClef = ##t  \key g \minor d8 |

However, what happens is that the natural sign is printed on top of the double bar line.  So either I need to not print the natural (which would be my preference), or somehow push the entire new key signature (one natural and two flats) after the clef sign.

Note that I’m not interested in modern best practice, but I want to (with modern music printing) maintain the spirit of the 18^th century manuscript.



The naturals are printed by a KeyCancellation grob, which has
break-align-symbol 'key-cancellation
(https://lilypond.org/doc/v2.23/Documentation/internals/keycancellation).
When overriding the order, you have not told LilyPond where to
put it. Just add key-cancellation to the vector before
key-signature.

\version "2.22.1"

\language english

global = {
  \clef treble
  \time 4/4
  \override Score.BreakAlignment.break-align-orders =
  #(make-vector 3 '(span-bar
                    breathing-sign
                    staff-bar
                    clef
                    key-cancellation
                    key-signature
                    time-signature))
}

\relative c' {
  \global
  \key g \major
  c4 d e fs |
  g a
  \bar "||"
  \set Staff.forceClef = ##t
  \key c \minor
  bf c |
  bf af g f |
  ef d c2
}


Best,
Jean




Reply via email to