]> git.donarmstrong.com Git - lilypond.git/blob - input/lsr/education/using-grid-lines-to-emphasize-rhythms-and-notes-synchronization.ly
Merge branch 'master' of git://git.sv.gnu.org/lilypond
[lilypond.git] / input / lsr / education / using-grid-lines-to-emphasize-rhythms-and-notes-synchronization.ly
1 %%  Do not edit this file; it is auto-generated from LSR!
2 \version "2.11.23"
3
4 \header { texidoc = "
5 Regular vertical lines can be drawn between staves to show notes
6 synchronization; however, in case of monophonic music, you may want to
7 make the second stave invisible, and make the lines shorter like in
8 this snippet.
9 " }
10
11 %% sets of grid
12 \layout {
13  \context {
14    \Staff
15    \consists "Grid_point_engraver"
16    gridInterval = #(ly:make-moment 1 8)
17 %% lines length
18    \override GridPoint #'Y-extent = #'(6 . 0)
19  }
20  \context {
21    \StaffGroup
22    \remove "System_start_delimiter_engraver"
23  }
24 }
25
26 \layout {
27  ragged-right = ##t
28 }
29 \new Score
30 \with {
31  \consists "Grid_line_span_engraver"
32 %% centers grid lines  horizontally below noteheads
33  \override NoteColumn #'X-offset = #-0.5
34 }
35
36 \new ChoirStaff <<
37  \new Staff
38  {
39    \time 12/8
40    \stemUp
41    \relative {
42    c'4. d8 e8 f g4 f8 e8.[ d16 c8] }
43  }
44  \new Staff
45  {
46 %% making sure the lines will be placed outside the Staff
47    \override Score.GridLine #'extra-offset = #'( 0.0 . -4.0 )
48
49 %% hides staff and notes so that only the grid lines are visible
50    \override NoteHead #'transparent = ##t
51    \override NoteHead #'no-ledgers = ##t
52    \override Stem #'transparent = ##t
53    \override Beam #'transparent = ##t
54    \override Staff.BarLine #'transparent = ##t
55    \override Staff.StaffSymbol #'line-count = #0
56    \override Staff.TimeSignature #'transparent = ##t
57    \override Staff.Clef #'transparent = ##t
58
59 % you have to put 'dummy' notes here to force regular grid spacing...
60  \once  \override Score.GridLine #'thickness = #4.0
61  c8   c8   c8
62  \once  \override Score.GridLine #'thickness = #3.0
63  c8   c8   c8
64  \once  \override Score.GridLine #'thickness = #4.0
65  c8   c8   c8
66  \once  \override Score.GridLine #'thickness = #3.0
67  c8   c8   c8
68  }
69 >>