]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/separating-key-cancellations-from-key-signature-changes.ly
5f81f13b4d2ef93303e6f3604aa4c28f92cc3e8a
[lilypond.git] / Documentation / snippets / separating-key-cancellations-from-key-signature-changes.ly
1 %% DO NOT EDIT this file manually; it is automatically
2 %% generated from LSR http://lsr.dsi.unimi.it
3 %% Make any changes in LSR itself, or in Documentation/snippets/new/ ,
4 %% and then run scripts/auxiliar/makelsr.py
5 %%
6 %% This file is in the public domain.
7 \version "2.17.6"
8
9 \header {
10   lsrtags = "pitches, tweaks-and-overrides"
11
12   texidoc = "
13 By default, the accidentals used for key cancellations are placed
14 adjacent to those for key signature changes.  This behavior can be
15 changed by overriding the @code{'break-align-orders} property of the
16 @code{BreakAlignment} grob.
17
18
19 The value of @code{'break-align-orders} is a vector of length 3, with
20 quoted lists of breakable items as elements.  This example only
21 modifies the second list, moving @code{key-cancellation} before
22 @code{staff-bar}; by modifying the second list, break alignment
23 behavior only changes in the middle of a system, not at the beginning
24 or the end.
25
26 "
27   doctitle = "Separating key cancellations from key signature changes"
28 } % begin verbatim
29
30 \new Staff {
31   \override Score.BreakAlignment.break-align-orders =
32     #'#((left-edge ambitus breathing-sign clef staff-bar
33                    key-cancellation key-signature time-signature custos)
34
35         (left-edge ambitus breathing-sign clef key-cancellation
36                    staff-bar key-signature time-signature custos)
37
38         (left-edge ambitus breathing-sign clef key-cancellation
39                    key-signature staff-bar time-signature custos))
40
41   \key des \major
42   c'1
43   \bar "||"
44   \key bes \major
45   c'1
46 }