X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=Documentation%2Flearning%2Ffundamental.itely;h=b936ca497169b425dba7f9b7063d327305c23d16;hb=08c1ead90d9f49e66ce54208639fb9ef48ca52a6;hp=8f3076bc4a3580a0d2144554bc856b62feedb15d;hpb=98ac53591234404cd70c5eebd370a598ec74095b;p=lilypond.git diff --git a/Documentation/learning/fundamental.itely b/Documentation/learning/fundamental.itely index 8f3076bc4a..b936ca4971 100644 --- a/Documentation/learning/fundamental.itely +++ b/Documentation/learning/fundamental.itely @@ -178,7 +178,7 @@ Two more commands you have not previously seen are shown they will cause LilyPond to produce a printed output and a MIDI output respectively. They are described fully in the Notation Reference -- @ruser{Score layout}, and -@ruser{Creating MIDI files}. +@ruser{Creating MIDI output}. @cindex scores, multiple @cindex book block, implicit @@ -519,8 +519,8 @@ So, for example, a phrasing slur can start before a manually inserted beam and end before the end of the beam -- not very musical, perhaps, but possible: -@lilypond[quote,verbatim,ragged-right,relative=2] -g8\( a b[ c b\) a] g4 +@lilypond[quote,verbatim,ragged-right] +\relative { g'8\( a b[ c b\) a] g4 } @end lilypond In general, different kinds of brackets, bracket-like constructs, @@ -530,11 +530,13 @@ a slur extending into a tuplet (line 2), a beam and a slur extending into a tuplet, a tie crossing two tuplets, and a phrasing slur extending out of a tuplet (lines 3 and 4). -@lilypond[quote,verbatim,ragged-right,relative=1] -r16[ g \tuplet 3/2 { r16 e'8] } -g,16( a \tuplet 3/2 { b16 d) e } -g,8[( a \tuplet 3/2 { b8 d) e~] } | -\tuplet 5/4 { e32\( a, b d e } a4.\) +@lilypond[quote,verbatim,ragged-right] +\relative { + r16[ g' \tuplet 3/2 { r16 e'8] } + g,16( a \tuplet 3/2 { b16 d) e } + g,8[( a \tuplet 3/2 { b8 d) e~] } | + \tuplet 5/4 { e32\( a, b d e } a4.\) +} @end lilypond @@ -586,9 +588,11 @@ A single voice can contain many notes in a chord, of course, so when exactly are multiple voices needed? Look first at this example of four chords: -@lilypond[quote,verbatim,ragged-right,relative=1] -\key g \major -4 +@lilypond[quote,verbatim,ragged-right] +\relative { + \key g \major + 4 +} @end lilypond This can be expressed using just the single angle bracket chord @@ -621,22 +625,26 @@ of polyphony. Here's how we split the chords above into two voices and add both the passing note and a slur: -@lilypond[quote,verbatim,ragged-right,relative=2] -\key g \major -% Voice "1" Voice "2" -<< { g4 fis8( g) a4 g } \\ { d4 d d d } >> +@lilypond[quote,verbatim,ragged-right] +\relative { + \key g \major + % Voice = "1" Voice = "2" + << { g'4 fis8( g) a4 g } \\ { d4 d d d } >> +} @end lilypond Notice how the stems of the second voice now point down. Here's another simple example: -@lilypond[quote,verbatim,ragged-right,relative=2] -\key d \minor -% Voice "1" Voice "2" -<< { r4 g g4. a8 } \\ { d,2 d4 g } >> | -<< { bes4 bes c bes } \\ { g4 g g8( a) g4 } >> | -<< { a2. r4 } \\ { fis2. s4 } >> | +@lilypond[quote,verbatim,ragged-right] +\relative { + \key d \minor + % Voice = "1" Voice = "2" + << { r4 g' g4. a8 } \\ { d,2 d4 g } >> | + << { bes4 bes c bes } \\ { g4 g g8( a) g4 } >> | + << { a2. r4 } \\ { fis2. s4 } >> | +} @end lilypond It is not necessary to use a separate @code{<< \\ >>} construct @@ -645,19 +653,20 @@ can help the legibility of the code, but if there are many notes in each bar it may be better to split out each voice separately, like this: -@lilypond[quote,verbatim,ragged-right,relative=2] -\key d \minor -<< { - % Voice "1" - r4 g g4. a8 | - bes4 bes c bes | - a2. r4 | -} \\ { - % Voice "2" - d,2 d4 g | - g4 g g8( a) g4 | - fis2. s4 | -} >> +@lilypond[quote,verbatim,ragged-right] +<< + \key d \minor + \relative { % Voice = "1" + r4 g' g4. a8 | + bes4 bes c bes | + a2. r4 | + } \\ + \relative { % Voice = "2" + d'2 d4 g | + g4 g g8( a) g4 | + fis2. s4 | + } +>> @end lilypond @@ -681,7 +690,7 @@ of slurs, stems, ties, dynamics etc., is set appropriately. \new Staff \relative { % Main voice c'16 d e f - % Voice "1" Voice "2" Voice "3" + % Voice = "1" Voice = "2" Voice = "3" << { g4 f e } \\ { r8 e4 d c8~ } >> | << { d2 e } \\ { c8 b16 a b8 g~ 2 } \\ { s4 b c2 } >> | } @@ -1374,8 +1383,8 @@ appear explicitly in the input file must be added to the output. For example, compare the input and output of the following example: -@lilypond[quote,verbatim,relative=2] -cis4 cis2. | a4 a2. | +@lilypond[quote,verbatim] +\relative { cis''4 cis2. | a4 a2. | } @end lilypond The input is rather sparse, but in the output, bar lines, @@ -1814,17 +1823,19 @@ font size, which affects the size of the note heads (among other things) several times. The change is from the default value, not the most recently set value. -@lilypond[quote,verbatim,ragged-right,relative=1] -c4 d -% make note heads smaller -\set fontSize = #-4 -e4 f | -% make note heads larger -\set fontSize = #2.5 -g4 a -% return to default size -\unset fontSize -b4 c | +@lilypond[quote,verbatim,ragged-right] +\relative { + c'4 d + % make note heads smaller + \set fontSize = #-4 + e4 f | + % make note heads larger + \set fontSize = #2.5 + g4 a + % return to default size + \unset fontSize + b4 c | +} @end lilypond We have now seen how to set the values of several different types of