]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/changing-time-signatures-inside-a-polymetric-section-using--scaledurations.ly
Issue 5167/6: Changes: show \markup xxx = ... \etc assignments
[lilypond.git] / Documentation / snippets / changing-time-signatures-inside-a-polymetric-section-using--scaledurations.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 = "contemporary-notation, contexts-and-engravers, rhythms, workaround"
11
12   texidoc = "
13 The @code{measureLength} property, together with
14 @code{measurePosition}, determines when a bar line is needed.  However,
15 when using @code{\\scaleDurations}, the scaling of durations makes it
16 difficult to change time signatures.  In this case,
17 @code{measureLength} should be set manually, using the
18 @code{ly:make-moment} callback.  The second argument must be the same
19 as the second argument of @code{\\scaleDurations}.
20
21 "
22   doctitle = "Changing time signatures inside a polymetric section using \\scaleDurations"
23 } % begin verbatim
24
25 \layout {
26   \context {
27     \Score
28     \remove "Timing_translator"
29     \remove "Default_bar_line_engraver"
30   }
31   \context {
32     \Staff
33     \consists "Timing_translator"
34     \consists "Default_bar_line_engraver"
35   }
36 }
37
38 <<
39   \new Staff {
40     \scaleDurations 8/5 {
41       \time 6/8
42       \set Timing.measureLength = #(ly:make-moment 6/5)
43       b8 b b b b b
44       \time 2/4
45       \set Timing.measureLength = #(ly:make-moment 4/5)
46       b4 b
47     }
48   }
49   \new Staff {
50     \clef bass
51     \time 2/4
52     c2 d e f
53   }
54 >>