-@cindex paper size
-@cindex page size
-@cindex @code{papersize}
-
-To change the paper size, you must first set the
-@code{papersize} paper variable variable. Set it to
-the strings @code{a4}, @code{letter}, or @code{legal}. After this
-specification, you must set the font as described above. If you want
-the default font, then use the 20 point font.
-
-@example
- \paper@{ papersize = "a4" @}
- \include "paper16.ly"
-@end example
-
-The file @code{paper16.ly} will now include a file named @file{a4.ly}, which
-will set the paper variables @code{hsize} and @code{vsize} (used by
-Lilypond and @code{ly2dvi})
-
-@c . {Line break}
-@node Line break
-@subsection Line break
-
-@cindex line breaks
-@cindex breaking lines
-
-Line breaks are normally computed automatically. They are chosen such
-that the resulting spacing has low variation, and looks neither cramped
-nor loose.
-
-Occasionally you might want to override the automatic breaks; you can do
-this by specifying @code{\break}. This will force a line break at this
-point. Do remember that line breaks can only occur at places where there
-are bar lines. If you want to have a line break where there is no
-bar line, you can force an invisible bar line by entering @code{\bar
-""}. Similarly, @code{\noBreak} forbids a line break at a certain point.
-
-@cindex @code{\penalty}
-
-The @code{\break} and @code{\noBreak} commands are defined in terms of
-the penalty command:
-@example
- \penalty @var{int}
-@end example
-
-This encourages or discourages LilyPond to make a line break at this
-point.
-
-@refbugs
-
-The scaling of the @code{\penalty} argument is not well-defined. The
-command is rather kludgey, and slated for rewriting.
-
-@c . {Page break}
-@node Page break
-@subsection Page break
-
-@cindex page breaks
-@cindex breaking pages
-
-Page breaks are normally computed by @TeX{}, so they are not under
-direct control of LilyPond. However, you can insert a commands into the
-@file{.tex} output to instruct @TeX{} where to break pages, by inserting
-the command @code{\newpage}
-@cindex @code{\newpage}
-
-@example
- \newpage
-@end example
-
-@c why do so difficult?
-@c maybe should explain contents of between-system.ly,
-@c but not now, we're talking about page breaks here.
-@c For more
-@c details, see the example file @file{input/test/between-systems.ly}
-
-
-@c . {Output scaling}
-@node Output scaling
-@subsection Output scaling
-
-[TODO]
-
-@example
-dvips ...
-@end example
-
-@example
-pstops ...
-@end example
-
-
-@refbugs
-
-There is no mechanism to select magnification of particular fonts,
-meaning that you don't have access to continuously scaled fonts.
-
-
-
-@c . {Output formats}
-@node Output formats
-@section Output formats
-
-LilyPond can output processed music in different output formats.
-
-@menu
-* TeX output::
-* PostScript output::
-* Scheme output::
-* ASCIIScript output::
-@end menu
-
-@node TeX output
-@subsection TeX output
-@cindex TeX output
-
-LilyPond will use @TeX{} by default. Even if you want to produce
-PostScript output for viewing or printing, you should normally have
-LilyPond produce @TeX{} first. The .tex output must be processed by
-@TeX{} (@strong{not} La@TeX{}) to generate a .dvi. Then, @file{Dvips}
-is used to generate PostScript. Alternatively, @file{ly2dvi} can be
-used to generate the .dvi for you.
-
-@refbugs
-
-Titling is not generated unless you use @file{ly2dvi}.
-
-
-@node PostScript output
-@subsection PostScript output
-@cindex PostScript output
-@cindex direct PostScript output
-
-LilyPond can produce PostScript directly, without going through @TeX{}.
-Currently, this is mainly useful if you cannot use TeX, because direct
-PostScript output has some problems; see Bugs below.
-
-@example
-$ lilypond -fps foo.ly
-GNU LilyPond 1.3.144
-Now processing: `foo.ly'
-Parsing...
-Interpreting music...[3]
-Preprocessing elements...
-Calculating column positions...
-paper output to foo.ps...
-
-$ cat /usr/share/lilypond/pfa/feta20.pfa foo.ps | lpr
-@end example
-
-
-@refbugs
-
-Text font selection is broken.
-
-The .ps file does not contain the .pfa font files. To print a .ps
-created through direct postscript output, you should prepend the
-necessary .pfa files to LilyPond's .ps output, or upload them to the
-printer before printing.
-
-The line height calculation is broken, you must set @var{lineheight} in
-the paperblock if you have more than one staff in your score, e.g.
-
-@example
- ...
- \paper @{
- % Set line height to 40 staff spaces
- lineheight = 40
- @}
-@end example
-
-@node Scheme output
-@subsection Scheme output
-@cindex Scheme output
-
-In the typesetting stage, LilyPond builds a page description, which is
-then written to disk in postscript, @TeX{} or ASCII art. Before it is
-written, the page description is represented as Scheme expressions. You
-can also dump these Scheme expressions to a file, which may be
-convenient for debugging output routines. This is done with the Scheme
-output format
-
-@example
-$ lilypond -fscm foo.ly
-GNU LilyPond 1.3.144
-Now processing: `foo.ly'
-Parsing...
-Interpreting music...[3]
-Preprocessing elements...
-Calculating column positions...
-paper output to foo.scm...
-
-$ head -4 foo.scm
-;;; Usage: guile -s x.scm > x.tex
- (primitive-load-path 'standalone.scm)
-; (scm-tex-output)
- (scm-ps-output)
-
-$ guile -s foo.scm > foo.tex
-@end example
-
-
-@node ASCIIScript output
-@subsection ASCIIScript output
-@cindex ASCIIScript output
-@cindex ascii script
-@cindex ascii art
-
-LilyPond can output ASCII Art. This is a two step process, LilyPond
-produces an ASCII description file, dubbed ASCIIScript (extension
-@file{.as}). ASCIIScript has a small and simple command set that
-includes font selection, character and string printing and line drawing
-commands. The program @file{as2text} is used to translate an .as file
-to text.
-
-To produce ASCII Art, you must include an ASCII Art paper definition
-file in your .ly, one of:
-@example
-\include "paper-as5.ly"
-\include "paper-as9.ly"
-@end example
-
-Here's an example use for ASCII Art output (the example file
-@file{as-email.ly} is included in the LilyPond distribution), the staff
-symbol has been made invisible:
-
-@example
-$ lilypond -fas as-email.ly
-GNU LilyPond 1.3.144
-Now processing: `as-email.ly'
-Parsing...
-Interpreting music...[3]
-Preprocessing elements...
-Calculating column positions... [2]
-paper output to as-email.as...
-
-$ as2text as-email.as 2>/dev/null
- |\
- |/ |##|##| | | | | |
- /| | | | | |\ |\ |\ |\ |\ |
- / |_ 3 | | | | 5 | )| )| )| )| )|
- | /| \ 8 * * * | 8 * * * * * |
- \_|_/ | |
- *_|
-
- lily
-@end example
-
-
-@refbugs
-
-The ASCII Art fonts are far from complete and not very well designed.
-It's easy to change the glyphs, though; if you think you can do better,
-have a look at @file{mf/*.af}.
-
-Lots of resizable symbols such as slurs, ties and tuplets are missing.
-
-The poor looks of most ASCII Art output and its limited general
-usefulness gives ASCII Art output a low priority; it may be
-dropped in future versions.
-
-@c . {Sound}
-@node Sound
-@section Sound
-@cindex Sound
-
-LilyPond can produce MIDI output. The performance lacks lots of
-interesting effects, such as swing, articulation, slurring, etc., but it
-is good enough for proof-hearing the music you have entered. Ties,
-dynamics and tempo changes are interpreted.
-
-Dynamic marks, crescendi and decrescendi translate into MIDI volume
-levels. Dynamic marks translate to a fixed fraction of the available
-MIDI volume range, crescendi and decrescendi make the the volume vary
-linearly between their two extremities. The fractions be adjusted by
-overriding the @code{absolute-volume-alist} defined in
-@file{scm/midi.scm}.
-
-For each type of musical instrument (that MIDI supports), a volume range
-can be defined. This gives you basic equalizer control, which can
-enhance the quality of the MIDI output remarkably. You can add
-instruments and ranges or change the default settings by overriding the
-@code{instrument-equalizer-alist} defined in @file{scm/midi.scm}.
-
-Both loudness controls are combined to produce the final MIDI volume.
-
-
-@refbugs
-
-It is currently not possible to use the percussion channel (generally
-channel 10 of a MIDI file).
-
-@menu
-* MIDI block::
-* MIDI instrument names::
-@end menu
-
-@c . {MIDI block}
-@node MIDI block
-@subsection MIDI block
-@cindex MIDI block
-
-
-The MIDI block is analogous to the paper block, but it is somewhat
-simpler. The @code{\midi} block can contain:
-@cindex MIDI block
-
-@itemize @bullet
- @item a @code{\tempo} definition
- @item context definitions
-@end itemize
-
-Assignments in the @code{\midi} block are not allowed.
-
-
-
-@cindex context definition
-
-Context definitions follow precisely the same syntax as within the
-\paper block. Translation modules for sound are called performers.
-The contexts for MIDI output are defined in @file{ly/performer.ly}.
-
-
-@node MIDI instrument names
-@subsection MIDI instrument names
-
-@cindex instrument names
-@cindex @code{Staff.midiInstrument}
-@cindex @code{Staff.instrument}
-
-The MIDI instrument name is set by the @code{Staff.midiInstrument}
-property or, if that property is not set, the @code{Staff.instrument}
-property. The instrument name should be chosen from the list in
-@ref{MIDI instruments}.
-
-@refbugs
-
-If the selected string does not exactly match, then LilyPond uses the
-default (Grand Piano). It is not possible to select an instrument by
-number.
-
-
-
-
-
-
-
-
-@c FIXME: Note entry vs Music entry at top level menu is confusing.
-@c . {Music entry}
-@node Music entry
-@section Music entry
-@cindex Music entry
-@menu
-* Relative::
-* Bar check::
-* Point and click::
-@end menu
-
-When entering music with LilyPond, it is easy to introduce errors. This
-section deals with tricks and features that help you enter music, and
-find and correct mistakes.
-
-@c . {Relative}
-@node Relative
-@subsection Relative
-@cindex Relative
-@cindex relative octave specification
-
-Octaves are specified by adding @code{'} and @code{,} to pitch names.
-When you copy existing music, it is easy to accidentally put a pitch in
-the wrong octave and hard to find such an error. To prevent these
-errors, LilyPond features octave entry.
-
-@cindex @code{\relative}
-@example
- \relative @var{startpitch} @var{musicexpr}
-@end example
-
-The octave of notes that appear in @var{musicexpr} are calculated as
-follows: If no octave changing marks are used, the basic interval
-between this and the last note is always taken to be a fourth or less
-(This distance is determined without regarding alterations; a
-@code{fisis} following a @code{ceses} will be put above the
-@code{ceses})
-
-The octave changing marks @code{'} and @code{,} can be added to raise or
-lower the pitch by an extra octave. Upon entering relative mode, an
-absolute starting pitch must be specified that will act as the
-predecessor of the first note of @var{musicexpr}.
-
-Entering music that changes octave frequently is easy in relative mode.
-@lilypond[fragment,singleline,verbatim,center]
- \relative c'' {
- b c d c b c bes a
- }
-@end lilypond
-
-And octave changing marks are used for intervals greater than a fourth.
-@lilypond[fragment,verbatim,center]
- \relative c'' {
- c g c f, c' a, e'' }
-@end lilypond
-
-If the preceding item is a chord, the first note of the chord is used
-to determine the first note of the next chord. However, other notes
-within the second chord are determined by looking at the immediately
-preceding note.
-
-@lilypond[fragment,verbatim,center]
- \relative c' {
- c <c e g>
- <c' e g>
- <c, e' g>
- }
-@end lilypond
-@cindex @code{\notes}
-
-The pitch after the @code{\relative} contains a note name. To parse
-the pitch as a note name, you have to be in note mode, so there must
-be a surrounding @code{\notes} keyword (which is not
-shown here).
-
-The relative conversion will not affect @code{\transpose},
-@code{\chords} or @code{\relative} sections in its argument. If you
-want to use relative within transposed music, you must place an
-additional @code{\relative} inside the @code{\transpose}.
-
-
-@c . {Bar check}
-@node Bar check
-@subsection Bar check
-@cindex Bar check
-
-@cindex bar check
-@cindex @code{barCheckNoSynchronize}
-@cindex @code{|}
-
-
-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 find errors in the input. Depending on the value of
-@code{barCheckNoSynchronize}, the beginning of the measure will be
-relocated, so this can also be used to shorten measures.
-
-A bar check is entered using the bar symbol, @code{|}:
-@example
- \time 3/4 c2 e4 | g2.
-@end example
-
-
-
-@cindex skipTypesetting
-
-Failed bar checks are most often caused by entering incorrect
-durations. Incorrect durations often completely garble up the score,
-especially if it is polyphonic, so you should start correcting the score
-by scanning for failed bar checks and incorrect durations. To speed up
-this process, you can use @code{skipTypesetting} (See @ref{Skipping
-corrected music})). Bar
-
-
-@c . {Point and click}
-@node Point and click
-@subsection Point and click
-
-Point and click lets you find notes in the input by clicking on them in
-the Xdvi window. This makes it very easy to find input that causes some
-error in the sheet music.
-
-To use it, you need the following software
-
-@unnumberedsubsec Installation
-
-@itemize @bullet
-@item
-@uref{ftp://ftp.math.berkeley.edu/pub/Software/TeX/xdvi.tar.gz,plain
-Xdvi} version 22.36 or newer.
-
- Note that most @TeX{} distributions ship with xdvik, which is a
- different and less well maintained program. To find out which xdvi you
- are running, try @code{xdvi --version} or @code{xdvi.bin --version}.
-@item emacs
-@end itemize
-
-Xdvi must be configured to find the TeX fonts and music
-fonts. Refer to the Xdvi documentation for more information.
-
-
-@unnumberedsubsec Using it
-
-Add one of these lines to the top of your .ly file. The first one is for
-line location only. The second one is more convenient, but requires
-patching @code{emacsclient} and @code{server.el}.
-
-@example
-#(set! point-and-click line-location)
-@end example
-
-In the emacs startup file (usually @file{~/.emacs}), add the following
-@example
-(server-start)
-@end example
-
-Make sure that the environment variable @code{XEDITOR} is set
-to
-@example
-emacsclient --no-wait +%l %f
-@end example
-The second one, that also specifies the column, only works if you have
-patched your emacsclient and server, and have compiled your @code{.ly}
-file using the @code{line-column-location} setting.
-
-When viewing, control-mousebutton 1 will take you to the originating
-spot in the @file{.ly} file. Control-mousebutton 2 will show all
-clickable boxes.
-
-
-@unnumberedsubsec Column location
-
-If you want emacs to jump to the exact spot (and not just the line) on a
-click, you must enable column positioning. To do so, you need to patch
-emacsclient. Apply @file{emacsclient.patch} (included with the source
-package) to @file{emacsclient.c} and @file{server.el} from the emacs
-source code. Recompile and stick the recompiled emacsclient into a bin
-directory, and put @file{server.el} into a elisp directory
-(e.g. @file{~/usr/share/emacs/}). Add the following to your @file{.emacs}
-init file, before invoking server-start.
-
-@example
- (setq load-path (cons "~/usr/share/emacs" load-path))
-@end example
-
-Set @code{XEDITOR} to @code{emacsclient --no-wait +%l:%c %f}
-
-At the top of the @code{ly} file, replace the @code{set!} line with the
-following line
-@example
-#(set! point-and-click line-column-location)
-@end example
-
-One final hint: if you correct large files with point-and-click, then
-start correcting at the end of the file. When you start at the top, and
-insert one line, all subsequent locations will be off by a line.
-
-
-@refbugs
-
-When you convert the @TeX{} file to PostScript using @code{dvips}, it
-will complain about not finding @code{src:X:Y} files. Those complaints
-are harmless, and can be ignored.
-
-@node Skipping corrected music
-@section Skipping corrected music
-
-The property @code{Score.skipTypesetting} can be used to switch on and
-off typesetting completely during the interpretation phase. When
-typesetting is switched off, the music is processed much more quickly.
-You can use this to skip over the parts of a score that you have already
-checked for errors.
-
-@lilypond[fragment,singleline,verbatim]
-\relative c'' { c8 d
-\property Score.skipTypesetting = ##t
- e f g a g c, f e d
-\property Score.skipTypesetting = ##f
-c d b bes a g c2 }
-@end lilypond
-
-
-@node Interpretation context
-@section Interpretation context
-
-@menu
-* Creating contexts::
-* Default contexts::
-* Context properties::
-* Engravers and performers::
-* Changing context definitions::
-* Defining new contexts::
-@end menu
-
-
-Interpretation contexts are objects that only exist during a run of
-LilyPond. During the interpretation phase of LilyPond (when it prints
-"interpreting music"), the music expression in a @code{\score} block is
-interpreted in time order. This is the same order that humans hear and
-play the music.
-
-During this interpretation, the interpretation context holds the
-state for the current point within the music. It contains information
-like
-
-@itemize @bullet
- @item What notes are playing at this point?
- @item What symbols will be printed at this point?
- @item What is the current key signature, time signature, point within
- the measure, etc.?
-@end itemize
-
-Contexts are grouped hierarchically: A @internalsref{Voice} context is
-contained in a @internalsref{Staff} context (because a staff can contain
-multiple voices at any point), a @internalsref{Staff} context is contained in
-@internalsref{Score}, @internalsref{StaffGroup}, or @internalsref{ChoirStaff} context.
-
-Contexts associated with sheet music output are called @emph{notation
-contexts}, those for sound output are called @emph{performance
-contexts}. The default definitions of the standard notation and
-performance contexts can be found in @file{ly/engraver.ly} and
-@file{ly/performer.ly}, respectively.
-
-
-@node Creating contexts
-@subsection Creating contexts