Two \partCombine pairs on one staff: Difference between revisions

Import snippet from LSR
 
mNo edit summary
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
The <code>\partCombine</code> function takes two music expressions each containing a part, and distributes them among four <code>Voice</code>s named “two”, “one”, “solo”, and “chords” depending on when and how the parts are merged into a common voice. The voices output from <code>\partCombine</code> can have their layout properties adjusted in the usual way. Here we define extensions of <code>\partCombine</code> to make it easier to put four voices on a staff.
The <code>\partCombine</code> function takes two music expressions each containing a part, and distributes them among four <code>Voice</code>s named “two”, “one”, “solo”, and “chords” depending on when and how the parts are merged into a common voice. The voices output from <code>\partCombine</code> can have their layout properties adjusted in the usual way. Here we define extensions of <code>\partCombine</code> to make it easier to put four voices on a staff.
The original version can be input as follows.


<pre>soprano = { d'4 | cis'  b  e'  d'8 cis' | cis'2 b }
<pre>soprano = { d'4 | cis'  b  e'  d'8 cis' | cis'2 b }
Line 6: Line 8:
bass = { fis8 gis | a4 gis g fis | eis fis b,2 }
bass = { fis8 gis | a4 gis g fis | eis fis b,2 }


\new Staff &lt;&lt;
\new Staff <<
   \key b\minor  
   \key b\minor  
   \clef alto
   \clef alto
Line 13: Line 15:
   \partCombineUp \soprano \alto
   \partCombineUp \soprano \alto
   \partCombineDown \tenor \bass
   \partCombineDown \tenor \bass
&gt;&gt;</pre>
>></pre>
 
And here is the extended snippet.


<lilypond version="2.24.0">
<lilypond version="2.24">
\layout {
\layout {
   \context {
   \context {
Line 85: Line 89:
</lilypond>
</lilypond>


[[Category:Scheme]]
[[Category:Simultaneous notes]]
[[Category:Simultaneous notes]]
[[Category:Staff notation]]
[[Category:Staff notation]]
[[Category:Included in the official documentation]]
[[Category:Included in the official documentation]]
[[Category:Snippet]]