-
+@c TODO:
+@c - Reinsert subsection commands that were lost in the
+@c ancient conversion from YODL! /MB
+@c - Restructure! Separate internal commands from user level commands. /MB
+@c - Add some words about Guile. /MB
+@c - Fix indexing (keyindex) so it doesn't add line breaks /MB
@node Reference Manual, , , Top
@menu
@example
\header @{ @var{key1} = @var{val1};
- @var{key2} = @var{val2}; @dots{} @}
+ @var{key2} = @var{val2}; @dots{} @}
@end example
A header describes the file's contents. It can also appear in a
deutsch.ly c d e f g a b h -is -es
norsk.ly c d e f g a b h -iss/-is -ess/-es
svenska.ly c d e f g a b h -iss -ess
-italiano.ly do re mi fa sol la sid si -d -b
-catalan.ly do re mi fa sol la sid si -d/-s -b
+italiano.ly do re mi fa sol la sib si -d -b
+catalan.ly do re mi fa sol la sib si -d/-s -b
@end example
Pitch names can be redefined using the
is that a word can end with `@code{@}}', which may be confusing if
you thought the closing brace was going to terminate Lyrics
mode.@footnote{LilyPond will issue a warning, though.} Any
- `@code{_}' characters which appear in an unquoted word are
- converted to spaces. This provides a mechanism for introducing
+ `@code{_}' character which appears in an unquoted word is
+ converted to a space. This provides a mechanism for introducing
spaces into words without using quotes. Quoted words can also be
used in Lyrics mode to specify words that cannot be written with
the above rules. Here are some examples. Not all of these words
@cindex upstep
-`@code{|}' is a barcheck. Whenever a barcheck is encountered during
+`@code{|}' is a bar check. Whenever a bar check is encountered during
interpretation, a warning message is issued if it doesn't fall at a
measure boundary. This can help you finding errors in the input.
The beginning of the measure will be relocated, so this can also
@mudela[verbatim,fragment]
\addlyrics
\transpose c'' {
- \property Voice.automaticMelismata = "1"
+ \property Voice.automaticMelismata = ##t
c8 () cis d8. e16 f2
}
\context Lyrics \lyrics {
@mudela[fragment,verbatim,center]
<
- \property Score.chordInversion = 1
+ \property Score.chordInversion = ##t
\context ChordNameVoice \notes {
<e'1 g' c''>
}
of the famous menuet in J. S. Bach's @emph{Klavierbuechlein}.
@mudela[verbatim]
-% lines preceded by a percent are comments.
+% lines preceded by a percent are comments which
+% are ignored by Lilypond.
\include "paper16.ly"
\score {
\notes
Let's try to redo this
@example
- % lines preceded by a percent are comments.
+ % lines preceded by a percent are comments which
+ % are ignored by Lilypond.
+
@end example
The percent sign, `@code{%}', introduces a line comment. If you want to
@end example
This command tells LilyPond that the following piece of music must
-be played twice; @code{"volta"} volta brackets should be used for
-alternatives---if there were any.
+be played twice; @code{"volta"} means that volta brackets should be used
+for alternatives---if there were any.
@example
@{
d4 g, g |
@end example
- Three more notes. The `@code{|}' character is a `barcheck'. When
-processing the music, LilyPond will verify that barchecks are found at
+ Three more notes. The `@code{|}' character is a `bar check'. When
+processing the music, LilyPond will verify that bar checks are found at
the start of a measure. This can help you track down errors.
So far, no notes were chromatically altered. Here is the first one
@end example
The next line shows how to make a slur:
the beginning and ending note of the slur is marked with an opening and
-closing parenthesis respectively. In the line shown above this is
-done for two slurs. Slur markers (parentheses) are between
+closing parenthesis respectively. In the line shown above, this is
+done for two slurs. Slur markers (parentheses) are put between
the notes.
@example
@end example
Automatic beaming can be overridden by inserting beam marks
-(brackets). Brackets are put around notes you want beamed.
+(brackets). Brackets are put around the notes you want beamed.
@example
g2. |
@end example
This line shows that Lily will print an accidental if that is
-needed: the first C sharp will be printed with an accidental, the
-second one without.
+needed: the first C sharp of the bar will be printed with an accidental,
+the second one without.
@example
a8-. b-. cis-. d-. e-. fis-.
@end example
You can enter articulation signs either in a verbose form using a
shorthand. Here we demonstrate the shorthand: it is formed by a dash
-and the the character for the articulation to use, e.g. `@code{-.}' for
+and the character for the articulation to use, e.g. `@code{-.}' for
staccato as shown above.
@example
\include "paper16.ly"
melody = \notes \relative c' @{
\partial 8;
+ \key c \minor;
g8 |
c4 c8 d [es () d] c4 | f4 f8 g [es() d] c g |
c4 c8 d [es () d] c4 | d4 es8 d c4.
\addlyrics
\context Staff = mel @{
- \property Staff.noAutoBeaming = "1"
- \property Staff.automaticMelismata = "1"
+ \property Staff.noAutoBeaming = ##t
+ \property Staff.automaticMelismata = ##t
\melody
@}
\context Lyrics \text
@}
- \midi @{ @}
+ \midi @{ \tempo 4=72;@}
\paper @{ linewidth = 10.0\cm; @}
@}
@end example
\addlyrics
\context Staff = mel {
- \property Staff.noAutoBeaming = "1"
- \property Staff.automaticMelismata = "1"
+ \property Staff.noAutoBeaming = ##t
+ \property Staff.automaticMelismata = ##t
\melody
}
\context Lyrics \text
}
- \midi { }
+ \midi { \tempo 4=72;}
\paper { linewidth = 10.0\cm; }
}
@end mudela
with a string. (which is unquoted, in this case). Then comes the
equal sign `@code{=}'. After the equal sign comes the expression you
want to store. In this case, you want to put in strings. The
-information has to be quoted here, because it contains spaces. The
+information has to be quoted here, because it contains spaces. Each
assignment is finished with a semicolon.
@example
The piece starts with an anacrusis of one eighth.
@example
- \key c \minor
+ \key c \minor;
@end example
The key is C minor: we have three flats.
The note heads alone make no sense, they need surrounding information:
a key signature, a clef, staff lines, etc. They need @emph{context}. In
LilyPond, these symbols are created by objects called `interpretation
-context'. Interpretation contexts only exist during a run of
+contexts'. Interpretation contexts only exist during a run of
LilyPond. Interpretation contexts that are for printing music (as
-opposed to playing music) are called `notation context'.
+opposed to playing music) are called `notation contexts'.
-By default, LilyPond will create a Staff contexts for you. If you
-would remove the @code{%} sign in the previous line, you can see that
+By default, LilyPond will create a Staff context for you. If you
+removed the @code{%} sign in the previous line, you would see that
mechanism in action.
-We don't want default contexts here, because we want names, not note
-heads. An interpretation context can also created upon explicit
+We don't want default contexts here, because we want chord names, not
+note heads. An interpretation context can also created upon explicit
request. The keyword for such a request is @code{\context}. It takes
-two arguments. The first is the name of a interpretation context.
+two arguments. The first is the name of an interpretation context.
The name is a string, it can be quoted with double quotes). The
second argument is the music that should be interpreted in this
context. For the previous line, we could have written @code{\context
@end example
This is the argument of @code{\addlyrics}. We instantiate a
-@code{Staff} context explicitly: should you chose to remove comment
+@code{Staff} context explicitly: should you chose to remove the comment
before the ``note heads'' version of the accompaniment, the
accompaniment will be on a nameless staff. The melody has to be on a
different staff as the accompaniment. This is accomplished by giving
the melody staff a different name.
@example
- \property Staff.noAutoBeaming = "1"
+ \property Staff.noAutoBeaming = ##t
@end example
An interpretation context has variables that tune its behaviour. One
staff.
@example
- \property Staff.automaticMelismata = "1"
+ \property Staff.automaticMelismata = ##t
@end example
Similarly, we don't want to print a syllable when there is
This ends @code{\simultaneous}.
@example
- \midi @{ @}
+ \midi @{ \tempo 4=72;@}
@end example
This makes the music go to a MIDI file. MIDI is great for
checking music you enter. You listen to the MIDI file: if you hear
something unexpected, it's probably a typing error. @code{\midi} is an
`output definition', a declaration that specifies how to output music
-analogous to @code{\paper @{ @}}.
+analogous to @code{\paper @{ @}}. You can specify the tempo using the
+@code{\tempo} command, in this case the tempo of quarter notes is set
+to 72 beats per minute.
@example
\paper @{ linewidth = 10.0\cm; @}
@node Piano music, , , Tutorial
@section Piano music
-Our third subject is a piece piano music. The fragment in the input
+Our third subject is a piece of piano music. The fragment in the input
file is a piano reduction of the G major Sinfonia by Giovanni Battista
Sammartini. It was composed around 1740.
@mudela[verbatim]
+\version "1.3.56";
\include "paper16.ly";
viola = \notes \relative c' \context Voice = viola {
bassvoices = \notes \relative c' {
c4 g8. b,16
- \hoomPahHoomPah \hoomPahHoomPah \hoomPahHoomPah \hoomPahHoomPah
+ \repeat unfold 4 {\hoomPahHoomPah}
\stemdown [c8 c'8] r4
<g d'> r4
< {\stemup r2 <e4 c'> <c8 g'> }
\score {
\context PianoStaff \notes <
\context Staff = top < \time 2/2;
- \context Voice = viola \viola
+ \viola
\oboes
>
\context Staff = bottom < \time 2/2; \clef bass;
right. The author has doctored this example to have as many quirks in
one system as possible.
@example
+\version "1.3.56";
+@end example
+Lilypond and the Mudela language is still under development, therefore
+it is useful to indicate the Lilypond version of the file. Lilypond
+will check the version number and warn you when the syntax has
+changed. Also, the @code{convert-mudela} program will be able to
+update most of the syntax changes automatically.
+@example
viola = \notes \relative c' \context Voice = viola @{
@end example
In this example, you can see multiple parts on a staff. Each part is
associated with one notation context. This notation context handles
stems and dynamics (among others). The name of this context is
@code{Voice}. For each part we have to make sure that there is
-precisely one Voice context@footnote{If @code{\context} would not
-have been specified explicitly, three @code{Voice} contexts would be
-created: one for each note in the first chord.}.
+precisely one Voice context.
@example
<c4-\f g' c>
@end example
When a grace section is processed, a @code{Grace} context is
created. This context acts like a miniature score of its own. It has
its own time bookkeeping, and you can make notes, beams, slurs
-etc. Here fiddle with a property and make a beam. The argument of
+etc. Here we fiddle with a property and make a beam. The argument of
@code{\grace} is sequential music.
@example
\property Grace.verticalDirection = \down
Put two of these fragments in sequence, and beam them.@example
bassvoices = \notes \relative c' @{
c4 g8. b,16
-\hoomPahHoomPah \hoomPahHoomPah \hoomPahHoomPah
-\hoomPahHoomPah
+\repeat unfold 4 {\hoomPahHoomPah}
@end example
Entering the bass part is easy: the hoomPahHoomPah variable is
-referenced four times.
+repeated four times; @code{unfold} means that all four repetitions
+should be written out.
@example
\context Voice = reallyLow @{\stemdown g2 ~ | g4 c8 @} >
@end example
indent = 0.0;
@end example
To make some more room on the line, the first (in this case the only)
-line is not indented. The line still looks is very cramped, but that is due
+line is not indented. The line still looks very cramped, but that is due
to the format of this tutorial.
This example shows a lot of features, but the organisation isn't