]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/how-to-print-two-rehearsal-marks-above-and-below-the-same-barline-method-2.ly
Issue 5167/6: Changes: show \markup xxx = ... \etc assignments
[lilypond.git] / Documentation / snippets / how-to-print-two-rehearsal-marks-above-and-below-the-same-barline-method-2.ly
1 %% DO NOT EDIT this file manually; it is automatically
2 %% generated from LSR http://lsr.di.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.18.0"
8
9 \header {
10   lsrtags = "editorial-annotations, expressive-marks, staff-notation, tweaks-and-overrides"
11
12   texidoc = "
13 This method prints two 'rehearsal marks' - one above the stave and one
14 below, by creating two voices, adding the Rehearsal Mark engraver to
15 each voice - without this no rehearsal mark is printed - and then
16 placing each rehearsal mark UP and DOWN in each voice respectively.
17
18 This method (as opposed to method 1) is more complex, but allows for
19 more flexibility, should it be needed to tweak each rehearsal mark
20 independently of the other.
21
22 "
23   doctitle = "How to print two rehearsal marks above and below the same barline (method 2)"
24 } % begin verbatim
25
26 \score {
27   \relative c'
28   <<
29     \new Staff {
30       <<
31         \new Voice \with {
32           \consists Mark_engraver
33           \consists "Staff_collecting_engraver"
34         }
35         { c4 d e f
36           \mark \markup { \box A }
37           c4 d e f
38         }
39         \new Voice \with {
40           \consists Mark_engraver
41           \consists "Staff_collecting_engraver"
42           \override RehearsalMark.direction = #DOWN
43         }
44         { s4 s s s
45           \mark \markup { \circle 1 }
46           s4 s s s
47         }
48       >>
49     }
50   >>
51   \layout {
52     \context {
53       \Score
54       \remove "Mark_engraver"
55       \remove "Staff_collecting_engraver"
56     }
57   }
58 }