blob: ecdbe1797ee075ddd9912f1fa030fcbe94c20a00 (
about) (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
|
%% DO NOT EDIT this file manually; it is automatically
%% generated from LSR http://lsr.di.unimi.it
%% Make any changes in LSR itself, or in Documentation/snippets/new/ ,
%% and then run scripts/auxiliar/makelsr.py
%%
%% This file is in the public domain.
\version "2.18.0"
\header {
= "preparing-parts, template, unfretted-strings"
= "
The @qq{String quartet template} snippet produces a nice string
quartet, but what if you needed to print parts? This new template
demonstrates how to use the @code{\\tag} feature to easily split a
piece into individual parts.
You need to split this template into separate files; the filenames are
contained in comments at the beginning of each file. @code{piece.ly}
contains all the music definitions. The other files – @code{score.ly},
@code{vn1.ly}, @code{vn2.ly}, @code{vla.ly}, and @code{vlc.ly} –
produce the appropriate part.
Do not forget to remove specified comments when using separate files!
"
= "String quartet template with separate parts"
} % begin verbatim
%%%%% piece.ly
%%%%% (This is the global definitions file)
global= {
\time 4/4
\key c \major
}
Violinone = \new Voice { \relative c''{
\set Staff.instrumentName = #"Violin 1 "
c2 d e1
\bar "|." }} %*********************************
Violintwo = \new Voice { \relative c''{
\set Staff.instrumentName = #"Violin 2 "
g2 f e1
\bar "|." }} %*********************************
Viola = \new Voice { \relative c' {
\set Staff.instrumentName = #"Viola "
\clef alto
e2 d c1
\bar "|." }} %*********************************
Cello = \new Voice { \relative c' {
\set Staff.instrumentName = #"Cello "
\clef bass
c2 b a1
\bar "|."}} %**********************************
music = {
<<
\tag #'score \tag #'vn1 \new Staff { << \global \Violinone >> }
\tag #'score \tag #'vn2 \new Staff { << \global \Violintwo>> }
\tag #'score \tag #'vla \new Staff { << \global \Viola>> }
\tag #'score \tag #'vlc \new Staff { << \global \Cello>> }
>>
}
%%% These are the other files you need to save on your computer
%%%%% score.ly
%%%%% (This is the main file)
%%% uncomment the line below when using a separate file
%\include "piece.ly"
#(set-global-staff-size 14)
\score {
\new StaffGroup \keepWithTag #'score \music
\layout { }
\midi { }
}
%{ Uncomment this block when using separate files
%%%%% vn1.ly
%%%%% (This is the Violin 1 part file)
\include "piece.ly"
\score {
\keepWithTag #'vn1 \music
\layout { }
}
%%%%% vn2.ly
%%%%% (This is the Violin 2 part file)
\include "piece.ly"
\score {
\keepWithTag #'vn2 \music
\layout { }
}
%%%%% vla.ly
%%%%% (This is the Viola part file)
\include "piece.ly"
\score {
\keepWithTag #'vla \music
\layout { }
}
%%%%% vlc.ly
%%%%% (This is the Cello part file)
\include "piece.ly"
\score {
\keepWithTag #'vlc \music
\layout { }
}
%}
|