pats
tags
test-output-distance
+Documentation/user/lilypond
<br>
<strong>@DATE@</strong>
</p>
+
+ <p>
+ <strong>Achtung:</strong> Diese Übersetzung befindet sich noch in der Entwicklung, <br>
+ die englische Version (Link unten auf der Seite) bietet die
+ vollständige Fassung der Dokumentation.
+ </p>
</div>
<table align="center">
# todo: add latex.
PDF_FILES = $(TELY_FILES:%.tely=$(outdir)/%.pdf)
+# this prevents aux files from being reused for translated docs
+TEXI2PDF_FLAGS = --tidy
INFO_DOCS = lilypond lilypond-internals music-glossary lilypond-program lilypond-learning
INFO_FILES = $(INFO_DOCS:%=$(outdir)/%.info)
+ifeq ($(out),www)
+INFO_IMAGES_DIR = lilypond
+endif
+
STEPMAKE_TEMPLATES=tex texinfo omf documentation
-#TEXI2DVI_FLAGS = -E
OMF_FILES += $(outdir)/lilypond-internals.html.omf
LOCALSTEPMAKE_TEMPLATES=lilypond ly
ifeq ($(out),www)
# This builds all .info targets with images, in out-www.
-# Viewawble with a recent Emacs, doing: M-x info out-www/lilypond.info
+# Viewable with a recent Emacs, doing: C-u C-h i out-www/lilypond.info
# Cancel the special, non-image info generation rule that skips images:
$(outdir)/%.info: $(outdir)/%.nexi
+# "makeinfo --info" MUST be able to read PNGs from CWD for info images
+# to work, hence lilypond/ -> $(outdir)/ symlink.
+# $(outdir)/lilypond/*.png symlinks are only needed to view
+# out-www/*.info with Emacs -- HTML docs no longer need these
+# symlinks, see replace_symlinks_urls in
+# buildscripts/add_html_footer.py.
+$(outdir)/%.info: lilypond
+lilypond: $(OUT_PNG_IMAGES)
+ rm -f lilypond
+ ln -s $(outdir) lilypond
+ mkdir -p $(outdir)/lilypond
+ find $(outdir)/lilypond/ -name '*'.png | xargs rm -f
+ (cd $(outdir)/lilypond/ ; ln -sf ../*.png . )
+
local-install-info: info
- -$(INSTALL) -d $(DESTDIR)$(package_infodir)
+ -$(INSTALL) -d $(DESTDIR)$(infodir)
ifneq ($(patsubst %/local,%,$(DESTDIR)$(prefix)),/usr)
## Can not have absolute symlinks because some binary packages build schemes
## install files in nonstandard root. Best we can do is to notify the
@echo
@echo "For images in the INFO docs to work, do: "
@echo
- @echo " (cd $(package_infodir) && ln -sf ../../doc/lilypond/Documentation/user/*png .)"
+ @echo " (cd $(infodir) && ln -sfT ../doc/lilypond/html/Documentation/user lilypond)"
@echo "or add something like that to the postinstall script."
@echo
else # installing directly into standard /usr/...
- -$(INSTALL) -d $(DESTDIR)$(package_infodir)
+ -$(INSTALL) -d $(DESTDIR)$(infodir)
-install-info --remove --info-dir=$(infodir) $(outdir)/lilypond.info
-install-info --remove --info-dir=$(infodir) $(outdir)/lilypond-program.info
-install-info --remove --info-dir=$(infodir) $(outdir)/lilypond-learning.info
+ -install-info --remove --info-dir=$(infodir) $(outdir)/lilypond-internals.info
+ -install-info --remove --info-dir=$(infodir) $(outdir)/music-glossary.info
install-info --info-dir=$(infodir) $(outdir)/lilypond.info
- (cd $(package_infodir) && ln -sf $(webdir)/Documentation/user/*png .)
+ cd $(infodir) && ln -sfT $(webdir)/Documentation/user lilypond
endif # installing directly into standard /usr/...
local-uninstall-WWW:
- rm -f $(package_infodir)/*.png
+ rm -f $(infodir)/lilypond
else # out!=www
# Cancel the default info generation rule that generates images:
-$(outdir)/%.info: # $(outdir)/%.texi
+$(outdir)/%.info: $(outdir)/%.texi
local-install-info: info
-$(INSTALL) -d $(DESTDIR)$(package_infodir)
@echo "and read the extra instructions."
@echo
else # installing directly into standard /usr/...
- -$(INSTALL) -d $(DESTDIR)$(package_infodir)
+ -$(INSTALL) -d $(DESTDIR)$(infodir)
-install-info --remove --info-dir=$(infodir) $(outdir)/lilypond.info
-install-info --remove --info-dir=$(infodir) $(outdir)/lilypond-program.info
-install-info --remove --info-dir=$(infodir) $(outdir)/lilypond-learning.info
+ -install-info --remove --info-dir=$(infodir) $(outdir)/lilypond-internals.info
+ -install-info --remove --info-dir=$(infodir) $(outdir)/music-glossary.info
install-info --info-dir=$(infodir) $(outdir)/lilypond.info
@echo
@echo "***************************************************************"
default:
+local-clean:
+ rm -f lilypond
local-help: extra-local-help
extra-local-help:
@echo -e "\
- dvi update dvi documents\n\
info update info pages\n\
ps update PostScript documents\n\
xml update Docbook xml documentation\n\
$(outdir)/lilypond.nexi: $(outdir)/lilypond-internals.texi
#
-# The split user manual
+# Split manuals in HTML
#
-$(outdir)/lilypond/index.html: $(outdir)/lilypond.texi $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
- mkdir -p $(dir $@)
- $(MAKEINFO) -I$(outdir) --output=$(outdir)/lilypond --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
-# we /might/ switch to texi2html if it can be fixed:
-# echo "*************************************"
-# echo $<
-# cd $(outdir)
-# texi2html --output=$(outdir)/lilypond --css-include=$(top-src-dir)/Documentation/texinfo.css $<
- find $(outdir)/lilypond/ -name '*'.png -o -name '*'.ly | xargs rm -f
-# symbolic links to save space
- (cd $(outdir)/lilypond/ ; ln -sf ../*.png ../*.ly . )
+$(outdir)/lilypond/index.html: $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
+$(outdir)/lilypond-program/index.html: $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
+$(outdir)/lilypond-learning/index.html: $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
+$(outdir)/music-glossary/index.html: $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
-#
-# One big page user manual
-#
-$(outdir)/lilypond-big-page.html: $(outdir)/lilypond.texi $(OUT_PNG_IMAGES)
- $(MAKEINFO) -I$(outdir) --output=$@ --css-include=$(top-src-dir)/Documentation/texinfo.css --html --no-split -D bigpage --no-headers $<
#
-# The split program usage
+# Manuals in one big HTML page
#
-$(outdir)/lilypond-program/index.html: $(outdir)/lilypond-program.texi $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
- mkdir -p $(dir $@)
- $(MAKEINFO) -I$(outdir) --output=$(outdir)/lilypond-program --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
- find $(outdir)/lilypond-program/ -name '*'.png -o -name '*'.ly | xargs rm -f
-# symbolic links to save space
- (cd $(outdir)/lilypond-program/ ; ln -sf ../*.png ../*.ly . )
-
-#
-# The Learning Manual
-#
-$(outdir)/lilypond-learning/index.html: $(outdir)/lilypond-learning.texi $(OUT_PNG_IMAGES) $(OUT_EPS_IMAGES)
- mkdir -p $(dir $@)
- $(MAKEINFO) -I$(outdir) --output=$(outdir)/lilypond-learning --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
- find $(outdir)/lilypond-learning/ -name '*'.png -o -name '*'.ly | xargs rm -f
-# symbolic links to save space
- (cd $(outdir)/lilypond-learning/ ; ln -sf ../*.png ../*.ly . )
-
-
-#
-# One big page program usage
-#
-$(outdir)/lilypond-program-big-page.html: $(outdir)/lilypond-program.texi $(OUT_PNG_IMAGES)
- $(MAKEINFO) -I$(outdir) --output=$@ --css-include=$(top-src-dir)/Documentation/texinfo.css --html --no-split -D bigpage --no-headers $<
-
-#
-# One big page learning manual
-#
-$(outdir)/lilypond-learning-big-page.html: $(outdir)/lilypond-learning.texi $(OUT_PNG_IMAGES)
- $(MAKEINFO) -I$(outdir) --output=$@ --css-include=$(top-src-dir)/Documentation/texinfo.css --html --no-split -D bigpage --no-headers $<
-
-
-#
-# The split internals reference
-#
-$(outdir)/lilypond-internals/index.html: $(outdir)/lilypond-internals.texi
- mkdir -p $(dir $@)
- $(MAKEINFO) --output=$(outdir)/lilypond-internals --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
-
-#
-# One big page internals reference
-#
-$(outdir)/lilypond-internals-big-page.html: $(outdir)/lilypond-internals.texi
- $(MAKEINFO) --output=$@ --css-include=$(top-src-dir)/Documentation/texinfo.css --html --no-split -D bigpage --no-headers $<
-
-#
-# The split glossary
-#
-$(outdir)/music-glossary/index.html: $(outdir)/music-glossary.texi
- mkdir -p $(dir $@)
- $(MAKEINFO) --output=$(outdir)/music-glossary --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
- find $(outdir)/music-glossary/ -name '*'.png -o -name '*'.ly | xargs rm -f
-# symbolic links to save space
- (cd $(outdir)/music-glossary/ ; ln -sf ../*.png ../*.ly . )
+$(outdir)/lilypond-big-page.html: $(OUT_PNG_IMAGES)
+$(outdir)/lilypond-program-big-page.html: $(OUT_PNG_IMAGES)
+$(outdir)/lilypond-learning-big-page.html: $(OUT_PNG_IMAGES)
$(outdir)/lilypond.xml: $(outdir)/lilypond.texi
mkdir -p $(dir $@)
mkdir -p $(dir $@)
$(MAKEINFO) --output=$(outdir)/lilypond-internals --docbook $<
-$(outdir)/lilypond.pdf: $(OUT_PDF_IMAGES) $(OUT_PNG_IMAGES)
-
-$(outdir)/lilypond-program.pdf: $(OUT_PDF_IMAGES) $(OUT_PNG_IMAGES)
-
-$(outdir)/lilypond-learning.pdf: $(OUT_PDF_IMAGES) $(OUT_PNG_IMAGES)
+$(outdir)/lilypond.pdf $(outdir)/lilypond-program.pdf: $(OUT_PDF_IMAGES) $(OUT_PNG_IMAGES)
+$(outdir)/lilypond-learning.pdf $(outdir)/music-glossary.pdf: $(OUT_PDF_IMAGES) $(OUT_PNG_IMAGES)
$(outdir)/%.png: %.png
convert -depth 8 -geometry 50x50% $< $@
@rm -f $(@)
ln -sf ../../ $(@)
-$(outdir)/lilypond/source:
- @rm -f $(@)
- mkdir -p $(outdir)/lilypond
- ln -sf ../../../ $(@)
-
-$(outdir)/music-glossary/source:
- @rm -f $(@)
- mkdir -p $(outdir)/music-glossary
- ln -sf ../../../ $(@)
-
-$(outdir)/lilypond-program/source:
+$(outdir)/%/source:
@rm -f $(@)
- mkdir -p $(outdir)/lilypond-program
- ln -sf ../../../ $(@)
-
-$(outdir)/lilypond-learning/source:
- @rm -f $(@)
- mkdir -p $(outdir)/lilypond-learning
+ mkdir -p $(dir $@)
ln -sf ../../../ $(@)
local-WWW: $(HTML_FILES) $(DEEP_HTML_FILES)\
- $(datafiles) $(PDF_FILES) $(source-links) info info-dir
-
-info-dir:
- $(SHELL) $(buildscript-dir)/install-info-html.sh --dir=$(outdir) lilypond lilypond-internals music-glossary lilypond-program lilypond-learning
-
+ $(datafiles) $(PDF_FILES) $(source-links) info
$(outdir)/%.bib: %.bib
ln -f $< $@
$(top-build-dir)/mf/$(outconfbase)/feta16list.ly:
$(MAKE) -C $(top-src-dir)/mf
-$(outdir)/lilypond.texi: $(ITELY_FILES) $(ITEXI_FILES)
-$(outdir)/lilypond.nexi: $(ITELY_FILES) $(ITEXI_FILES)
+$(outdir)/lilypond.texi $(outdir)/lilypond-program.texi $(outdir)/lilypond-learning.texi: $(ITELY_FILES) $(ITEXI_FILES)
+$(outdir)/lilypond.nexi $(outdir)/lilypond-program.nexi $(outdir)/lilypond-learning.nexi: $(ITELY_FILES) $(ITEXI_FILES)
-# Prevent building music-glossary.texi from default target
-$(outdir)/music-glossary.nexi:
# Rules for the automatically generated documentation
@end menu
@node Ancient note heads
-@unnumberedsubsubsec Ancient note heads
+@subsubsection Ancient note heads
@cindex note heads, ancient
@node Ancient accidentals
-@unnumberedsubsubsec Ancient accidentals
+@subsubsection Ancient accidentals
@cindex accidentals
Examples: @c @lsrdir{ancient}
@node Ancient rests
-@unnumberedsubsubsec Ancient rests
+@subsubsection Ancient rests
@cindex rests, ancient
@node Ancient clefs
-@unnumberedsubsubsec Ancient clefs
+@subsubsection Ancient clefs
@cindex clefs
@node Ancient flags
-@unnumberedsubsubsec Ancient flags
+@subsubsection Ancient flags
@cindex flags
scope for mensural notation).
@node Ancient time signatures
-@unnumberedsubsubsec Ancient time signatures
+@subsubsection Ancient time signatures
@cindex time signatures
@node Ancient articulations
-@unnumberedsubsubsec Ancient articulations
+@subsubsection Ancient articulations
@cindex articulations
the right end of the episem line is often too far to the right.
@node Custodes
-@unnumberedsubsubsec Custodes
+@subsubsection Custodes
@cindex custos
@cindex custodes
@node Divisiones
-@unnumberedsubsubsec Divisiones
+@subsubsection Divisiones
@cindex divisio
@cindex divisiones
@node Ligatures
-@unnumberedsubsubsec Ligatures
+@subsubsection Ligatures
@cindex Ligatures
@end menu
@node White mensural ligatures
-@unnumberedsubsubsec White mensural ligatures
+@subsubsection White mensural ligatures
@cindex Mensural ligatures
@cindex White mensural ligatures
Horizontal spacing is poor.
@node Gregorian square neumes ligatures
-@unnumberedsubsubsec Gregorian square neumes ligatures
+@subsubsection Gregorian square neumes ligatures
@cindex Square neumes ligatures
@cindex Gregorian square neumes ligatures
@node Gregorian Chant contexts
-@unnumberedsubsubsec Gregorian Chant contexts
+@subsubsection Gregorian Chant contexts
@cindex VaticanaVoiceContext
@cindex VaticanaStaffContext
@node Mensural contexts
-@unnumberedsubsubsec Mensural contexts
+@subsubsection Mensural contexts
@cindex MensuralVoiceContext
@cindex MensuralStaffContext
@end menu
@node Bagpipe definitions
-@unnumberedsubsubsec Bagpipe definitions
+@subsubsection Bagpipe definitions
LilyPond contains special definitions for music for the Scottish
highland bagpipe; to use them, add
@node Bagpipe example
-@unnumberedsubsubsec Bagpipe example
+@subsubsection Bagpipe example
This is what the well known tune Amazing Grace looks like in bagpipe
notation.
@code{Score} can contain many @code{Staff} contexts.
@quotation
-@image{context-example,5cm,,}
+@sourceimage{context-example,5cm,,}
@end quotation
Each context has the responsibility for enforcing some notation rules,
@c really awkward; I just shoved this in here from the tutorial.
@node A lead sheet
-@unnumberedsubsubsec A lead sheet
+@subsubsection A lead sheet
@cindex Lead sheets
@cindex chords
@node Introducing chord names
-@unnumberedsubsubsec Introducing chord names
+@subsubsection Introducing chord names
@cindex chord names
LilyPond has support for printing chord names. Chords may be entered
@node Chords mode
-@unnumberedsubsubsec Chords mode
+@subsubsection Chords mode
@cindex Chords mode
In chord mode sets of pitches (chords) are entered with normal note
@node Printing chord names
-@unnumberedsubsubsec Printing chord names
+@subsubsection Printing chord names
@cindex printing chord names
@cindex chord names
@end menu
@node Selecting notation font size
-@unnumberedsubsubsec Selecting notation font size
+@subsubsection Selecting notation font size
@cindex font size
@cindex font size, selecting
@node Fingering instructions
-@unnumberedsubsubsec Fingering instructions
+@subsubsection Fingering instructions
@cindex fingering
@cindex finger change
@node Hidden notes
-@unnumberedsubsubsec Hidden notes
+@subsubsection Hidden notes
@cindex Hidden notes
@cindex Invisible notes
@node Coloring objects
-@unnumberedsubsubsec Coloring objects
+@subsubsection Coloring objects
@cindex colored objects
@cindex colors
@node Parentheses
-@unnumberedsubsubsec Parentheses
+@subsubsection Parentheses
@cindex ghost notes
@cindex notes, ghost
@node Stems
-@unnumberedsubsubsec Stems
+@subsubsection Stems
@cindex stem
@end menu
@node Balloon help
-@unnumberedsubsubsec Balloon help
+@subsubsection Balloon help
Elements of notation can be marked and named with the help of a
square balloon. The primary purpose of this feature is to explain
@node Grid lines
-@unnumberedsubsubsec Grid lines
+@subsubsection Grid lines
Vertical lines can be drawn between staves synchronized with the
notes.
@node Blank music sheet
-@unnumberedsubsubsec Blank music sheet
+@subsubsection Blank music sheet
@cindex sheet music, empty
@cindex staves, blank sheet
@node Analysis brackets
-@unnumberedsubsubsec Analysis brackets
+@subsubsection Analysis brackets
@cindex brackets
@cindex phrasing brackets
@end menu
@node Articulations and ornamentations
-@unnumberedsubsubsec Articulations and ornamentations
+@subsubsection Articulations and ornamentations
@cindex articulations
@cindex scripts
@node Dynamics
-@unnumberedsubsubsec Dynamics
+@subsubsection Dynamics
@cindex dynamics
@funindex \pppp
@end menu
@node Slurs
-@unnumberedsubsubsec Slurs
+@subsubsection Slurs
@cindex slurs
@node Phrasing slurs
-@unnumberedsubsubsec Phrasing slurs
+@subsubsection Phrasing slurs
@cindex phrasing slurs
@cindex phrasing marks
@node Breath marks
-@unnumberedsubsubsec Breath marks
+@subsubsection Breath marks
Breath marks are entered using @code{\breathe}:
@node Falls and doits
-@unnumberedsubsubsec Falls and doits
+@subsubsection Falls and doits
Falls and doits can be added to notes using the @code{\bendAfter}
command,
@end menu
@node Glissando
-@unnumberedsubsubsec Glissando
+@subsubsection Glissando
@cindex glissando
@funindex \glissando
@node Arpeggio
-@unnumberedsubsubsec Arpeggio
+@subsubsection Arpeggio
@cindex arpeggio
@cindex broken chord
@node Trills
-@unnumberedsubsubsec Trills
+@subsubsection Trills
Short trills are printed with @code{\trill} like normal
articulation; see @ref{Articulations and ornamentations}.
Notation Reference -- @ruser{Score layout} and
@ruser{Creating MIDI files}.
-The @code{\book} command allows
-several @code{\score} blocks to be combined into one output.
-If there are several @code{\book} blocks each one produces a
+You may code multiple @code{\score} blocks. Each will be
+treated as a separate score, but they will be all combined into
+a single output file. A @code{\book} command is not necessary
+-- one will be implicitly created. However, if you would like
+separate output files from one @code{.ly} file then the
+@code{\book} command should be used to separate the different
+sections: each @code{\book} block will produce a
separate output file. For details see @ruser{Multiple scores
in a book}.
contain many @code{Staff} contexts.
@quotation
-@image{context-example,5cm,,}
+@sourceimage{context-example,5cm,,}
@end quotation
Each context has the responsibility for enforcing some notation rules,
output. This is a crude way of modifying the output, but it
can sometimes be useful.
-@unnumberedsubsubsec Changing a single context
+@subsubsection Changing a single context
To remove an engraver from a single context we use the
@code{\with} command placed immediately after the context creation
>>
@end lilypond
-@unnumberedsubsubsec Changing all contexts of the same type
+@subsubsection Changing all contexts of the same type
The examples above show how to remove or add engravers to
individual contexts. It is also possible to remove or add
@}
@end example
-We don't need two @code{\version} commands. We'll need the @code{melody}
-section. We don't want two @code{\score} sections -- if we had two
-@code{\score}s, we'd get the two parts separately. We want them together,
-as a duet. Within the @code{\score} section, we don't need two
-@code{\layout} or @code{\midi}.
-
-If we simply cut and paste the @code{melody} section, we would end up with
-two @code{melody} sections. So let's rename them. We'll call the section
-for the soprano @code{sopranoMusic} and the section for the cello
-@code{celloMusic}. While we're doing this, let's rename @code{text}
-to be @code{sopranoLyrics}. Remember to rename both instances of all
-these names -- both the initial definition (the
+We don't need two @code{\version} commands. We'll need the
+@code{melody} section. We don't want two @code{\score} sections
+-- if we had two @code{\score}s, we'd get the two parts separately.
+We want them together, as a duet. Within the @code{\score}
+section, we don't need two @code{\layout} or @code{\midi}.
+
+If we simply cut and paste the @code{melody} section, we would
+end up with two @code{melody} definitions. This would not generate
+an error, but the second one would be used for both melodies.
+So let's rename them to make them distinct. We'll call the
+section for the soprano @code{sopranoMusic} and the section for
+the cello @code{celloMusic}. While we're doing this, let's rename
+@code{text} to be @code{sopranoLyrics}. Remember to rename both
+instances of all these names -- both the initial definition (the
@code{melody = \relative c' @{ } part) and the name's use (in the
@code{\score} section).
-While we're doing this, let's change the cello part's staff -- celli
-normally use bass clef. We'll also give the cello some different
-notes.
+While we're doing this, let's change the cello part's staff --
+celli normally use bass clef. We'll also give the cello some
+different notes.
@example
\version "2.11.38"
+
@end menu
@node String number indications
-@unnumberedsubsubsec String number indications
+@subsubsection String number indications
@cindex String numbers
@node Tablatures basic
-@unnumberedsubsubsec Tablatures basic
+@subsubsection Tablatures basic
@cindex Tablatures basic
Tablature notation is used for notating music for plucked string
@node Non-guitar tablatures
-@unnumberedsubsubsec Non-guitar tablatures
+@subsubsection Non-guitar tablatures
@cindex Non-guitar tablatures
You can change the tuning of the strings. A string tuning is given as
@node Banjo tablatures
-@unnumberedsubsubsec Banjo tablatures
+@subsubsection Banjo tablatures
@cindex Banjo tablatures
LilyPond has basic support for five stringed banjo. When making tablatures
@node Fret diagrams
-@unnumberedsubsubsec Fret diagrams
+@subsubsection Fret diagrams
@cindex fret diagrams
@cindex chord diagrams
@node Right hand fingerings
-@unnumberedsubsubsec Right hand fingerings
+@subsubsection Right hand fingerings
Right hand fingerings in chords can be entered using
@code{@var{note}-\rightHandFinger @var{finger}}
@node Other guitar issues
-@unnumberedsubsubsec Other guitar issues
+@subsubsection Other guitar issues
This example demonstrates how to include guitar position and
barring indications.
@end ifnottex
@end ifnotinfo
@ifinfo
-@c workaround for makeinfo-4.6: line breaks and multi-column cookies
-@image{henle-flat-bw,,,png} @image{baer-flat-bw,,,png}
-@image{lily-flat-bw,,,png}
+@image{lilypond/henle-flat-bw,,,png} @image{lilypond/baer-flat-bw,,,png}
+@image{lilypond/lily-flat-bw,,,png}
@end ifinfo
@item @tab
@ignore
Distributions will want to install lilypond.info in postinstall, doing:
- install-info --info-dir=/usr/share/info out/lilypond.info
+ install-info --info-dir=/usr/share/info out[-www]/lilypond.info
* Prepend GNU for dir, must be unique.
@c
-@c Info files are installed in subdirectories to allow images to be present.
-@c
-@dircategory LilyPond
+@c Info files are no longer installed in a subdirectory, images are
+@c expected to be found in lilypond/ subdirectory.
+@dircategory GNU LilyPond --- the music typesetter
@direntry
-* LilyPond: (lilypond/lilypond). The GNU music typesetter.
-* abc2ly: (lilypond/lilypond-program)Invoking abc2ly. Importing ABC.
-* convert-ly: (lilypond/lilypond-program)Invoking convert-ly. Older LilyPond versions.
-* etf2ly: (lilypond/lilypond-program)Invoking etf2ly. Importing Finale.
-* lilypond-book: (lilypond/lilypond-program)LilyPond-book. Integrating text and music.
-* midi2ly: (lilypond/lilypond-program)Invoking midi2ly. Importing MIDI.
+* LilyPond Learning Manual: (lilypond-learning). Start here.
+* Music Glossary: (music-glossary). For non-English users.
+* LilyPond: (lilypond). LilyPond Notation Reference.
+* LilyPond Internals Reference: (lilypond-internals). Definitions for tweaking.
+* LilyPond Application Usage: (lilypond-program). Installing and running applications.
+* abc2ly: (lilypond-program)Invoking abc2ly. Importing ABC.
+* convert-ly: (lilypond-program)Updating files with convert-ly. Older LilyPond versions.
+* etf2ly: (lilypond-program)Invoking etf2ly. Importing Finale.
+* lilypond-book: (lilypond-program)LilyPond-book. Integrating text and music.
+* midi2ly: (lilypond-program)Invoking midi2ly. Importing MIDI.
+* musicxml2ly: (lilypond-program)Invoking musicxml2ly. Importing MusicXML.
@end direntry
@c don't remove this comment.
@node LilyPond command index
@appendix LilyPond command index
+This index does blah blah blah.
+
@printindex ky
@node LilyPond index
@appendix LilyPond index
+In contrast, this index does blaz blaz blaz.
+
@printindex cp
@bye
@end quotation
@end macro
-@c TODO: define different output for info
+@ifnotinfo
@macro notation{TEXT}
@var{\TEXT\}
@end macro
+@end ifnotinfo
+@ifinfo
+@macro notation{TEXT}
+\TEXT\
+@end macro
+@end ifinfo
-
-@c **** Headings in a doc subsection ****
-
-@c not really a heading, but...
@macro smallspace
@sp 1
@end macro
+
+@c **** Displaying images not generated by lilypond-book
+
+@c current installation setup of Info docs requires that all images are
+@c expected to be found in lilypond/ subdirectory. lilypond-book already
+@c generates proper @image commands for images of music; these macros
+@c definitions do the same for other images.
+
+@ifnotinfo
+@macro sourceimage{FILENAME,WIDTH,HEIGHT,ALTTEXT}
+@image{\FILENAME\,\WIDTH\,\HEIGHT\,\ALTTEXT\}
+@end macro
+@end ifnotinfo
+
+@ifinfo
+@macro sourceimage{FILENAME,WIDTH,HEIGHT,ALTTEXT}
+@image{lilypond/\FILENAME\,\WIDTH\,\HEIGHT\,\ALTTEXT\}
+@end macro
+@end ifinfo
+
+
+@c **** Headings in a doc subsection ****
+
@c obsolete; being removed.
@macro refcommands
@noindent
@ifhtml
@c ***** HTML *****
-@c makeinfo-4.7 encodes html names, which means that nodes that
-@c contain nonalphanum characters will be broken links on the website.
-@c @uref{../lilypond-internals/\TEXT\.html,\TEXT\}@c
-@c @inforef{} adds ``See'' to the sentence, which is annoying, but
-@c better than a broken link.
-@c @inforef{\TEXT\,,lilypond-internals}@c
-@c using @ref without punctuation is OK without for formats other than info
-
@ifset bigpage
@macro internalsref{TEXT}
* lilypond::
* ligature::
* line::
+* loco::
* long appoggiatura::
* longa::
* lyrics::
* note head::
* note names::
* note value::
+* octavation::
* octave sign::
* octave::
* ornament::
* ossia::
-* ottava::
* part::
* pause::
* pennant::
* quadruplet::
* quarter note::
* quarter rest::
+* quarter tone::
* quintuplet::
* rallentando::
* relative key::
S: ?,
FI: ?.
-FIXME: this is a placeholder
+The pitch at which the piano and other nontransposing instruments play: such
+instruments are said to be @q{in C}. The following list includes some (but not
+all) instruments that play in concert pitch:
+
+@itemize
+
+@item Woodwinds
+@itemize
+@item flute
+@item oboe
+@item bassoon
+@end itemize
+
+@item Brass
+@itemize
+@item alto trombone
+@item tenor trombone
+@item bass trombone
+@end itemize
+
+@item Strings
+@itemize
+@item violin
+@item viola
+@item violincello
+@end itemize
+
+@item piano
+
+@end itemize
+
+The trombones are a special case: although they are said to be @q{in F} (alto or
+bass) or @q{in B-flat} (tenor), this refers to their fundamental note, not to
+their parts' transposition. (In fact, the trombones' parts are written at
+concert pitch with an appropriate clef -- alto, tenor or bass.) This differs
+from other instruments @q{in F}, @q{in B-flat}, and so on, which are transposing
+instruments.
+
+Instruments that play @q{in C} but in a different octave than what is written
+are, technically speaking, @emph{transposing instruments}:
+
+@itemize
+
+@item piccolo (plays an octave higher)
+@item celesta (plays an octave higher)
+@item double-bass (plays an octave lower)
+
+@end itemize
+
+@seealso
+
+@ref{transposing instrument}.
@node conjunct movement
indicated @samp{sul G}, another series to be played on the D string
would be indicated @samp{sul D}, and so on.
+@item
+With an octave indication (also called @emph{octavation}, q.v.) to indicate that
+a passage is to be played higher or lower by the given number of octaves.
+
@end itemize
@seealso
-@ref{melisma}, @ref{sul G}, @ref{thorough bass}
+@ref{melisma}, @ref{sul G}, @ref{thorough bass}, @ref{octavation}.
@node F
@ref{staff}.
+@node loco
+@section loco
+
+ES: ?,
+I: loco,
+F: ?,
+D: ?,
+NL: ?,
+DK: ?,
+S: ?,
+FI: ?.
+
+[From Italian, @q{place}]. Instruction to play the following passage at the
+written pitch. Cancels octavation (q.v.).
+
+@seealso
+
+@ref{octavation}.
+
+
@node long appoggiatura
@section long appoggiatura
@end lilypond
+@node octavation
+@section octavation
+
+ES: ?,
+I: ?,
+F: ?,
+D: ?,
+NL: ?,
+DK: ?,
+S: ?,
+FI: ?.
+
+The use of a phrase or abbreviation with an extender line or bracket to indicate
+that a passage is to be played in a different octave:
+
+@itemize
+
+@item @samp{15ma}: play two octaves higher
+@item @samp{8va}: play one octave higher
+@item @samp{8vb}: play one octave lower
+@item @samp{8va} written below the passage: same as @samp{8vb}
+@item @samp{15vb}: play two octaves lower
+@item @samp{15va} written below the passage: same as @samp{15vb}
+
+@end itemize
+
+Another practice, which may be useful for longer passages, is to indicate the
+different octave with a phrase at the beginning (see below). When the music
+returns to the written pitch, the octavation is cancelled with the word
+@emph{loco} (q.v.).
+
+To parallel the list above:
+
+@itemize
+
+@item @samp{15ma}: @emph{alla quindicesima (alta)}
+@item @samp{8va}: @emph{all'ottava} or @emph{ottava sopra}
+@item @samp{8vb}: @emph{ottava bassa}, @emph{ottava sotto}
+@item @samp{15vb}: @emph{alla quindicesima (bassa)}
+
+@end itemize
+
+@emph{Quindicesima} can be replaced with @emph{quindecima}, which is Latin.
+
+@seealso
+
+@ref{interval}, @ref{loco}, @ref{octave}.
+
+
@node octave sign
@section octave sign
+ES: ?,
+I: ?,
+F: ?,
+D: ?,
+NL: ?,
+DK: ?,
+S: ?,
+FI: ?.
+
+Putting 8 or 15 above or below the clef to indicate that the entire part is
+played in the indicated octave: a clef-wide octavation. An octave sign can be
+applied to any clef, though it is most frequently used with the G and F clefs.
+
@seealso
@ref{G clef}, @ref{F clef}.
S: oktav,
FI: oktaavi.
+The interval of an octave, sometimes abbreviated @samp{8ve}.
+
+For uses like @emph{all'ottava} or @emph{8va} with an extender line or
+bracket, or @samp{loco} see octavation.
+
@seealso
-@ref{ottava}, @ref{interval}.
+@ref{interval}, @ref{octavation}.
@node ornament
of the music, for example for small hands.
-@node ottava
-@section ottava
-
-@c TODO: translations
-
-ES: ?,
-I: ottava,
-F: octave,
-DE: Oktavierung,
-NL: ?,
-DK: ?,
-S: ?,
-FI: ?.
-
-[From Italian] The interval of an octave, abbreviated 8va.
-
-@emph{All'ottava}, @emph{ottava alta}, @emph{ottava sopra}, or
-@emph{8va} written above a passage indicates that it should be played
-an octave higher than written. @emph{Ottava bassa}, @emph{ottava
-sotto}, or @emph{8va} written below a passage indicates that it should
-be played an octave lower than written.
-
-@seealso
-
-@ref{interval}.
-
-
@node part
@section part
@ref{note value}.
+@node quarter tone
+@section quarter tone
+
+ES: ?,
+I: ?,
+F: quart de ton,
+D: Viertelton,
+NL: kwart toon,
+DK: ?,
+S: kvartston,
+FI: ?.
+
+An interval equal to half a semitone.
+
+@seealso
+
+@ref{interval}
+
+
@node quintuplet
@section quintuplet
S: ?,
FI: ?.
-FIXME: this is a placeholder
+Instruments whose notated pitch is different from their sounded pitch. Except
+for those whose notated and sounding pitches differ by one or more octaves (to
+reduce the number of ledger lines needed), most such instruments are identified
+by the letter name of the pitch class of their fundamental. The pitch class is
+the note that @emph{sounds} (disregarding the octave in which it sounds) when
+the instrument plays a notated C.
+
+For example: when played on the B-flat clarinet, the note middle C @emph{sounds}
+the B-flat one tone lower. If played on the A clarinet, the same written
+note sounds the A (one and half tones -- a minor third -- lower).
+
+Not all transposing instruments include the pitch class in their name:
+
+@itemize
+@item English horn (in F)
+@item Alto flute (in G)
+@end itemize
+
+@seealso
+
+@ref{concert pitch}.
@node transposition
@end menu
@node Repeats and MIDI
-@unnumberedsubsubsec Repeats and MIDI
+@subsubsection Repeats and MIDI
@cindex expanding repeats
@funindex \unfoldRepeats
@node Showing melody rhythms
-@unnumberedsubsubsec Showing melody rhythms
+@subsubsection Showing melody rhythms
Sometimes you might want to show only the rhythm of a melody. This
can be done with the rhythmic staff. All pitches of notes on such a
@node Entering percussion
-@unnumberedsubsubsec Entering percussion
+@subsubsection Entering percussion
@cindex percussion
@cindex drums
Internals Reference: @internalsref{note-event}.
@node Percussion staves
-@unnumberedsubsubsec Percussion staves
+@subsubsection Percussion staves
@cindex percussion
@cindex drums
@c TODO: check name -gp
@node Ghost notes
-@unnumberedsubsubsec Ghost notes
+@subsubsection Ghost notes
Ghost notes for drums and percussion may be created using the
@code{\parenthesize} command detailed in @ref{Parentheses}. However,
@node Automatic staff changes
-@unnumberedsubsubsec Automatic staff changes
+@subsubsection Automatic staff changes
@cindex Automatic staff changes
Voices can be made to switch automatically between the top and the bottom
@node Manual staff switches
-@unnumberedsubsubsec Manual staff switches
+@subsubsection Manual staff switches
@cindex manual staff switches
@cindex staff switch, manual
@node Pedals
-@unnumberedsubsubsec Pedals
+@subsubsection Pedals
@cindex Pedals
Pianos have pedals that alter the way sound is produced. Generally, a
Notation Reference: @ref{Ties} (laissez vibrer).
@node Staff switch lines
-@unnumberedsubsubsec Staff switch lines
+@subsubsection Staff switch lines
@cindex follow voice
@node Cross staff stems
-@unnumberedsubsubsec Cross staff stems
+@subsubsection Cross staff stems
Chords that cross staves may be produced by increasing the length
of the stem in the lower staff, so it reaches the stem in the upper
Snippets: @lsrdir{Pitches,Pitches}.
+@funindex \transpose
+@funindex \chordmode
+@funindex \relative
+
@refbugs
The relative conversion will not affect @code{\transpose},
@node Accidentals
@subsubsection Accidentals
+@cindex accidental
+@cindex key signature
+@cindex clef
+
@warning{New users are sometimes confused about accidentals and
key signatures. In LilyPond, note names are the raw input; key
signatures and clefs determine how this raw input is displayed.
@cindex note names, Dutch
@cindex note names, default
-
-A @notation{sharp} pitch is made by adding @code{is} to the name,
-and a @notation{flat} pitch by adding @code{es}. As you might
-expect, a @notation{double sharp} or @notation{double flat} is
-made by adding @code{isis} or @code{eses}. This syntax is derived
-from Dutch note naming conventions. To use other names for
-accidentals, see @ref{Note names in other languages}.
+@cindex sharp
+@cindex flat
+@cindex double sharp
+@cindex sharp, double
+@cindex double flat
+@cindex flat, double
+
+A @notation{sharp} pitch is made by adding @code{is} to the note name,
+and a @notation{flat} pitch by adding @code{es}. As you might expect,
+a @notation{double sharp} or @notation{double flat} is made by adding
+@code{isis} or @code{eses}. This syntax is derived from Dutch note
+naming conventions. To use other names for accidentals, see
+@ref{Note names in other languages}.
@lilypond[verbatim,quote,ragged-right,fragment,relative=2]
ais1 aes aisis aeses
@seealso
Music Glossary: @rglos{sharp}, @rglos{flat}, @rglos{double sharp},
-@rglos{double flat}, @rglos{Pitch names}.
+@rglos{double flat}, @rglos{Pitch names}, @rglos{quarter-tone}.
Learning Manual: @rlearning{Accidentals and key signatures}.
language files and the note names they define are:
@cindex note names, other languages
+@cindex pitch names, other languages
@smallexample
@multitable {nederlands.ly} {do re mi fa sol la sib si} {-iss/-is} {-ess/-es} {-ss/-x/-sharpsharp} {-essess/-eses}
@multitable {nederlands.ly} {do re mi fa sol la sib si} {-iss/-is} {-ess/-es} {-ississ/-isis} {-ississ/-isis}
@headitem Language
@tab Note names
- @tab semi- @tab semi- @tab sesqui- @tab sesqui-
+ @tab semi-sharp @tab semi-flat @tab sesqui-sharp @tab sesqui-flat
@item nederlands.ly
@tab c d e f g a bes b
}
@end lilypond
-The octave of pitches may also be checked with the
-@code{\octave}@tie{}@var{controlpitch} command.
-@var{controlpitch} is specified in absolute mode. This checks
-that the interval between the previous note and the
-@var{controlpitch} is within a fourth (i.e. the normal calculation
-of relative mode). If this check fails, a warning is printed, but
-the previous note is not changed. Future notes are relative to
-the @var{controlpitch}.
+The octave of notes may also be checked with the
+@code{\octave}@tie{}@var{controlpitch} command. @var{controlpitch} is
+specified in absolute mode. This checks that the interval between the
+previous note and the @var{controlpitch} is within a fourth (i.e. the
+normal calculation of relative mode). If this check fails, a warning
+is printed, but the previous note is not changed. Future notes are
+relative to the @var{controlpitch}.
@lilypond[verbatim,quote,ragged-right,fragment]
\relative c'' {
@end lilypond
Compare the two bars below. The first and third @code{\octave}
-check fail, but the second ones does not fail.
+check fail, but the second one does not fail.
@lilypond[verbatim,quote,ragged-right,fragment]
\relative c'' {
@subsubsection Transpose
@cindex transpose
+@cindex transposition
@cindex transposition of pitches
@funindex \transpose
Internals Reference: @internalsref{TransposedMusic}.
+@funindex \transpose
+@funindex \chordmode
+@funindex \relative
+
@refbugs
+
The relative conversion will not affect @code{\transpose},
@code{\chordmode} or @code{\relative} sections in its argument.
To use relative mode within transposed music, an additional
@subsubsection Clef
@funindex \clef
-
@cindex G clef
@cindex C clef
@cindex F clef
@cindex baritone clef
@cindex varbaritone clef
@cindex subbass clef
+@cindex clef
+@cindex ancient clef
+@cindex clef, ancient
+@cindex clef, G
+@cindex clef, C
+@cindex clef, F
+@cindex clef, treble
+@cindex clef, violin
+@cindex clef, alto
+@cindex clef, tenor
+@cindex clef, bass
+@cindex clef, french
+@cindex clef, soprano
+@cindex clef, mezzosoprano
+@cindex clef, baritone
+@cindex clef, varbaritone
+@cindex subbass clef, subbass
The clef is set with the @code{\clef} @var{clefname} command.
Middle C is shown in every example.
Further supported clefs are described under @ref{Ancient clefs}.
+@cindex transposing clefs
+@cindex clef, transposing
+@cindex octave transposition
+
By adding @code{_8} or @code{^8} to the clef name, the clef is
transposed one octave down or up, respectively, and @code{_15} and
@code{^15} transposes by two octaves. The argument @var{clefname}
\key @var{pitch} @var{mode}
@end example
-@funindex \minor
@funindex \major
@funindex \minor
@funindex \ionian
@funindex \phrygian
@funindex \dorian
@cindex church modes
+@cindex modes
Here, @var{mode} should be @code{\major} or @code{\minor} to get a
key signature of @var{pitch}-major or @var{pitch}-minor,
@seealso
-Music Glossary: @rglos{ottava}.
+Music Glossary: @rglos{octavation}.
Snippets: @lsrdir{Pitches,Pitches}.
@cindex transposition, MIDI
@cindex transposition, instrument
+@cindex transposing instrument
+@cindex MIDI
+@funindex \transposition
When typesetting scores that involve transposing instruments, some
parts can be typeset in a different pitch than the
@seealso
-Music Glossary: @rglos{concert pitch},
-@rglos{transposing instrument}.
+Music Glossary: @rglos{concert pitch}, @rglos{transposing instrument}.
Notation Reference: @ref{Quoting other voices}, @ref{Transpose}.
@node Automatic accidentals
@subsubsection Automatic accidentals
-@cindex automatic accidentals
+@cindex automatic accidentals
+@cindex accidentals, automatic
+@cindex accidentals
+@cindex accidental style
+@cindex default accidental style
+@cindex accidental style, default
@funindex set-accidental-style
There are many different conventions on how to typeset
@end lilypond
@item modern
+@cindex accidentals, modern style
+@cindex modern style accidentals
@funindex modern style accidentals
This rule corresponds to the common practice in the twentieth
@end lilypond
@item modern-cautionary
+@cindex accidentals, modern cautionary style
+@cindex modern style accidentals
+@cindex modern style cautionary accidentals
+@cindex modern accidental style
+@cindex modern cautionary accidental style
@funindex modern-cautionary
This rule is similar to @code{modern}, but the @q{extra}
@end lilypond
@item modern-voice
+@cindex accidentals, multivoice
+@cindex accidentals, modern
+@cindex modern accidentals
+@cindex multivoice accidentals
@funindex modern-voice
This rule is used for multivoice accidentals to be read both by
@end lilypond
@noindent
-To see all note head styles, please see @ref{Note head styles}.
+To see all note head styles, see @ref{Note head styles}.
@seealso
@node Repeat syntax
-@unnumberedsubsubsec Repeat syntax
+@subsubsection Repeat syntax
@cindex repeats
@node Normal repeats
-@unnumberedsubsubsec Normal repeats
+@subsubsection Normal repeats
@cindex volta
@cindex prima volta
@node Manual repeat commands
-@unnumberedsubsubsec Manual repeat commands
+@subsubsection Manual repeat commands
@funindex repeatCommands
@end menu
@node Tremolo repeats
-@unnumberedsubsubsec Tremolo repeats
+@subsubsection Tremolo repeats
@cindex tremolo beams
@node Measure repeats
-@unnumberedsubsubsec Measure repeats
+@subsubsection Measure repeats
@cindex percent repeats
@cindex measure repeats
@end menu
@node Durations
-@unnumberedsubsubsec Durations
+@subsubsection Durations
@cindex durations, of notes
@cindex note durations
note). For notes longer than a whole you must use the
@code{\longa} (a double breve) and @code{\breve} commands.
Durations as short as 64th notes may be specified. Shorter values
-are possible, but only as beamed notes:
+are possible, but only as beamed notes.
@c Two 64th notes are needed to obtain beams
@lilypond[quote,ragged-right,verbatim,fragment,relative=2]
@end lilypond
@noindent
-and the same durations with automatic beaming turned off;
-see @ref{Automatic beams}:
+Here are the same durations with automatic beaming turned off.
@c not strictly "writing rhythms"; more of a "displaying" thing,
@c but it's ok here. -gp
A note with the duration of a quadruple breve may be entered with
@code{\maxima}, but this is supported only within ancient music
-notation; see @ref{Ancient notation}.
+notation. For details, see @ref{Ancient notation}.
-If the duration is omitted then it is set to the previously
+If the duration is omitted, it is set to the previously
entered duration. The default for the first note is a quarter
note.
@end lilypond
Some durations cannot be represented with just binary durations
-and dots; they can only be represented by tying two or more
-notes together; see @ref{Ties}.
+and dots; they can be represented only by tying two or more
+notes together. For details, see @ref{Ties}.
For ways of specifying durations for the syllables of lyrics and
-ways of aligning lyrics to notes see @ref{Vocal music}.
+ways of aligning lyrics to notes, see @ref{Vocal music}.
-Optionally, notes can be spaced proportionately to their duration.
-For details of this and other settings which control proportional
-notation see @ref{Proportional notation}.
+Optionally, notes can be spaced strictly proportionately to their
+duration. For details of this and other settings which control
+proportional notation, see @ref{Proportional notation}.
@refcommands
@refbugs
-@c deliberately duplicated in Durations and Rests. -gp
+@c Deliberately duplicated in Durations and Rests. -gp
There is no fundamental limit to rest durations (both in terms of
-longest and shortest), but the number of glyphs is limited: there
-are rests from 128th to maxima (8 x whole).
+longest and shortest), but the number of glyphs is limited:
+rests from 128th to maxima (8 x whole) may be printed.
@node Tuplets
-@unnumberedsubsubsec Tuplets
+@subsubsection Tuplets
@cindex tuplets
@cindex triplets
@commonprop
+@cindex tuplet formatting
+@cindex triplet formatting
+
@funindex tupletNumberFormatFunction
@funindex tupletSpannerDuration
-@cindex tuplet formatting
+@c Sent to Snippet 5 Feb 08
The property @code{tupletSpannerDuration} specifies how long each
bracket should last. With this, you can make lots of tuplets
while typing @code{\times} only once, thus saving lots of typing.
@funindex TupletNumber
-The format of the number is determined by the property @code{text}
-in @code{TupletNumber}. The default prints only the denominator,
-but if the property is set with @code{\override
-TupletNumber #'text = #tuplet-number::calc-fraction-text},
-@var{num}:@var{den} will be printed instead.
+By default, only the numerator of the tuplet number
+is printed over the tuplet bracket, i.e. the denominator
+of the argument to the @code{\times} command. Alternatively,
+@var{num}:@var{den} of the tuplet number may be printed, or
+the tuplet number may be suppressed altogether.
-To print tuplets without tuplet numbers, use
-@code{\override TupletNumber #'transparent = ##t}:
@lilypond[quote,fragment,relative=2,ragged-right,verbatim]
\times 2/3 { c8 c c } \times 2/3 { c8 c c }
\times 2/3 { c8 c c }
@end lilypond
-To change the appearance of nested tuplets beginning at the same
-music moment individually, the @code{\tweak} function must be used
-(see @ref{Objects connected to the input}). In the following
-example, @code{\tweak} specifies fraction text for the outer
-@code{TupletNumber} and denominator text for the
-@code{TupletNumber} of the first of the three inner tuplets.
+@c TODO Add snippet to show this
+Tuplets may extend over bar lines, but they will inhibit a
+line break unless the @code{Forbid_line_break_engraver} is
+removed from the @code{Voice context}.
-@lilypond[quote,ragged-right,verbatim,fragment,relative=2]
+@subheading Modifying nested tuplets
+
+@cindex tuplets, nested
+@cindex triplets, nested
+@cindex bracket, tuplet
+@cindex tuplet bracket
+@cindex triplet bracket
+@funindex TupletBracket
+
+If nested tuplets do not begin at the same moment their
+appearance may be modified in the usual way with
+@code{\override} commands:
+
+@c NOTE Tuplet brackets collide if notes are high on staff
+@c See issue 509
+@lilypond[quote,ragged-right,verbatim,fragment,relative=1]
+\times 2/3 { c8[ c c]}
+\once \override TupletNumber #'text = #tuplet-number::calc-fraction-text
+\times 2/3 {
+ c[ c]
+ c[ c]
+ \once \override TupletNumber #'transparent = ##t
+ \times 2/3 { c8[ c c] }
+\times 2/3 { c8[ c c]}
+}
+@end lilypond
+
+However, if the nested tuplets begin at the same musical moment,
+@code{\override} commands cannot be applied to just one of them
+-- they apply to both. So to change the appearance of nested
+tuplets beginning at the same musical moment individually, the
+@code{\tweak} function must be used (see @ref{Objects connected
+to the input}). The @code{\tweak} function is applied to the
+following @code{\times} command as it appears in the input stream,
+and so can distinguish between separate @code{\times} commands
+even if their tuplets begin at the same musical moment.
+
+In this example, the @code{\tweak} command is used to specify
+fraction text for the outer @code{TupletNumber} and denominator
+text for the @code{TupletNumber} of the first of the three
+inner tuplets.
+
+@c NOTE Tuplet brackets collide if notes are high on staff
+@c so use relative=1 until this is fixed
+@c See issue 509
+@lilypond[quote,ragged-right,verbatim,fragment,relative=1]
\tweak #'text #tuplet-number::calc-fraction-text
\times 4/3 {
\tweak #'text #tuplet-number::calc-denominator-text
}
@end lilypond
-@cindex bracket, tuplet
-@funindex TupletBracket
-
-@c FIXME: after LM 6 Tweaks includes \tweak info, look at this.-gp
-@c It *should* be explained why \tweak must be used here, and why
-@c \override doesn't work. I've made an attempt, but I'm not sure
-@c if it is factually correct to say that \tweak must be used.
In the next example, @code{\tweak} and @code{\override} work
together to specify @code{TupletBracket} direction. The first
@code{\tweak} positions the @code{TupletBracket} of the outer
tuplet above the staff. The second @code{\tweak} positions the
@code{TupletBracket} of the first of the three inner tuplets below
-the staff. Note that the @code{\tweak} function affects only
-events that begin at the same music moment: the outer tuplet and
-the first of the three inner tuplets. To position the
-@code{TupletBrackets} of the second and third of the inner tuplets
-below the staff, we use @code{\override} in the usual way.
+the staff. Note that the @code{\tweak} command needs to be used
+only for events that begin at the same music moment: the outer
+tuplet and the first of the three inner tuplets. To position the
+@code{TupletBracket}s of the second and third of the inner tuplets
+below the staff, we can use @code{\override} in the usual way.
@lilypond[quote,ragged-right,verbatim,fragment,relative=2]
\tweak #'text #tuplet-number::calc-fraction-text
}
@end lilypond
-Tuplet brackets can be made to run to prefatory matter or the next
-note:
+@subheading Modifying tuplet bracket length
+
+@cindex tuplet bracket length
+@cindex triplet bracket length
+@cindex bracket length, tuplets
+@funindex tupletFullLength
+@funindex tupletFullLengthNote
+
+Tuplet brackets can be made to run to prefatory matter or the
+next note.
+Default tuplet brackets end at the right edge of the final note
+of the tuplet; full-length tuplet brackets extend farther to the
+right, either to cover all the non-rhythmic notation up to the
+following note, or to cover only the whitespace before the next
+item of notation, be that a clef, time signature, key signature,
+or another note. The example shows how to switch tuplets to
+full length mode and how to modify what material they cover.
+
@lilypond[ragged-right,verbatim,quote]
\new RhythmicStaff {
+ % Set tuplets to be extendable ..
\set tupletFullLength = ##t
+ % .. to cover all items up to the next note
\set tupletFullLengthNote = ##t
\time 2/4
\times 2/3 { c4 c c }
+ % .. or to cover just whitespace
\set tupletFullLengthNote = ##f
\time 4/4
\times 4/5 { c4 c1 }
}
@end lilypond
+@subheading Compressing music
+
+@cindex compressing music
@funindex \compressMusic
-@funindex \times
@code{\compressMusic} works similarly to \times, but does not
-create a tuplet bracket; see @ref{Polymetric notation}.
-
+create a tuplet bracket. One application is in polymetric
+notation, as shown in the following example. See
+@ref{Polymetric notation}.
-@refbugs
+@c not added yet. -gp
+@c @lilypondfile [ragged-right,line-width=16\cm,staffsize=14,quote]
+@c {printing-music-with-different-time-signatures.ly}
-Tuplets which cross bar lines will prevent a line break at that
-point.
@seealso
-Music Glossary: @rglos{tuplet}.
+Music Glossary: @rglos{triplet}, @rglos{tuplet},
+@rglos{polymetric}.
Notation Reference: @ref{Time administration},
@ref{Objects connected to the input}, @ref{Polymetric notation}.
@node Scaling durations
-@unnumberedsubsubsec Scaling durations
+@subsubsection Scaling durations
You can alter the length of a duration by a fraction @var{N/M}
by appending @code{*@var{N/M}} (or @code{*@var{N}} if @var{M=1}).
Snippets: @lsrdir{Rhythms,Rhythms}
@node Ties
-@unnumberedsubsubsec Ties
+@subsubsection Ties
@cindex tie
@funindex ~
@end menu
@node Rests
-@unnumberedsubsubsec Rests
+@subsubsection Rests
@cindex rest
@cindex maxima
@cindex longa
@refbugs
-@c duplicated in Durations and Rests. -gp
+@c Deliberately duplicated in Durations and Rests. -gp
There is no fundamental limit to rest durations (both in terms of
longest and shortest), but the number of glyphs is limited: there
are rests from 128th to maxima (8 x whole).
@node Skips
-@unnumberedsubsubsec Skips
+@subsubsection Skips
@cindex skip
@cindex invisible rest
@node Full measure rests
-@unnumberedsubsubsec Full measure rests
+@subsubsection Full measure rests
@cindex multi measure rests
@cindex full measure rests
@end menu
@node Time signature
-@unnumberedsubsubsec Time signature
+@subsubsection Time signature
@cindex time signature
@cindex meter
@node Upbeats
-@unnumberedsubsubsec Upbeats
+@subsubsection Upbeats
@cindex anacrusis
@cindex upbeat
Snippets: @lsrdir{Rhythms,Rhythms}
@node Unmetered music
-@unnumberedsubsubsec Unmetered music
+@subsubsection Unmetered music
@cindex cadenza
@funindex \cadenzaOn
@node Polymetric notation
-@unnumberedsubsubsec Polymetric notation
+@subsubsection Polymetric notation
@cindex double time signatures
@cindex signatures, polymetric
@node Automatic note splitting
-@unnumberedsubsubsec Automatic note splitting
+@subsubsection Automatic note splitting
Long notes which overrun bar lines can be converted automatically
to tied notes. This is done by replacing the
@end menu
@node Automatic beams
-@unnumberedsubsubsec Automatic beams
+@subsubsection Automatic beams
By default, beams are inserted automatically:
@node Setting automatic beam behavior
-@unnumberedsubsubsec Setting automatic beam behavior
+@subsubsection Setting automatic beam behavior
@funindex autoBeamSettings
@funindex (end * * * *)
@node Manual beams
-@unnumberedsubsubsec Manual beams
+@subsubsection Manual beams
@cindex beams, manual
@commonprop
@node Feathered beams
-@unnumberedsubsubsec Feathered beams
+@subsubsection Feathered beams
@cindex beams, feathered
@funindex \featherDurations
@end menu
@node Bar lines
-@unnumberedsubsubsec Bar lines
+@subsubsection Bar lines
@cindex bar lines
@funindex \bar
@node Bar numbers
-@unnumberedsubsubsec Bar numbers
+@subsubsection Bar numbers
@cindex bar numbers
@cindex measure numbers
@node Bar and bar number checks
-@unnumberedsubsubsec Bar and bar number checks
+@subsubsection Bar and bar number checks
@cindex bar check
@funindex barCheckSynchronize
@node Rehearsal marks
-@unnumberedsubsubsec Rehearsal marks
+@subsubsection Rehearsal marks
@cindex rehearsal marks
@cindex mark, rehearsal
@end menu
@node Grace notes
-@unnumberedsubsubsec Grace notes
+@subsubsection Grace notes
@funindex \grace
@cindex ornaments
supported, and might produce crashes or other errors.
@node Aligning to cadenzas
-@unnumberedsubsubsec Aligning to cadenzas
+@subsubsection Aligning to cadenzas
@cindex cadenza
@cindex cadenza, aligning to
@node Time administration
-@unnumberedsubsubsec Time administration
+@subsubsection Time administration
@cindex time administration
@cindex timing (within the score)
+
+
@end menu
@node Chorded notes
-@unnumberedsubsubsec Chorded notes
+@subsubsection Chorded notes
@cindex Chords
@node Clusters
-@unnumberedsubsubsec Clusters
+@subsubsection Clusters
@cindex cluster
@end menu
@node Collision resolution
-@unnumberedsubsubsec Collision resolution
+@subsubsection Collision resolution
@cindex merging notes
@cindex note collisions
@node Automatic part combining
-@unnumberedsubsubsec Automatic part combining
+@subsubsection Automatic part combining
@cindex automatic part combining
@cindex part combiner
@cindex combining parts
@node Writing music in parallel
-@unnumberedsubsubsec Writing music in parallel
+@subsubsection Writing music in parallel
@cindex Writing music in parallel
@cindex Interleaved music
@end menu
@node System start delimiters
-@unnumberedsubsubsec System start delimiters
+@subsubsection System start delimiters
@cindex start of system
@cindex staff, multiple
@node Staff symbol
-@unnumberedsubsubsec Staff symbol
+@subsubsection Staff symbol
@cindex adjusting staff symbol
@node Hiding staves
-@unnumberedsubsubsec Hiding staves
+@subsubsection Hiding staves
@cindex Frenched scores
@cindex staves, hiding
@end menu
@node Metronome marks
-@unnumberedsubsubsec Metronome marks
+@subsubsection Metronome marks
@cindex Tempo
@cindex beats per minute
@node Instrument names
-@unnumberedsubsubsec Instrument names
+@subsubsection Instrument names
@cindex instrument names
@cindex instrument names, short
@node Quoting other voices
-@unnumberedsubsubsec Quoting other voices
+@subsubsection Quoting other voices
@cindex cues
@cindex quoting other voices
@node Formatting cue notes
-@unnumberedsubsubsec Formatting cue notes
+@subsubsection Formatting cue notes
@cindex cues
@cindex cue notes
@end menu
@node Artificial harmonics (strings)
-@unnumberedsubsubsec Artificial harmonics (strings)
+@subsubsection Artificial harmonics (strings)
@cindex artificial harmonics
@end menu
@node Overview of text entry
-@unnumberedsubsubsec Overview of text entry
+@subsubsection Overview of text entry
There are four ways to add text to scores:
@node Text scripts
-@unnumberedsubsubsec Text scripts
+@subsubsection Text scripts
@cindex Text scripts
@cindex text items, non-empty
@node Text spanners
-@unnumberedsubsubsec Text spanners
+@subsubsection Text spanners
@cindex Text spanners
@node Text marks
-@unnumberedsubsubsec Text marks
+@subsubsection Text marks
@cindex coda on bar line
@cindex segno on bar line
@end menu
@node Text markup introduction
-@unnumberedsubsubsec Text markup introduction
+@subsubsection Text markup introduction
@cindex markup
@cindex text markup
@node Nested scores
-@unnumberedsubsubsec Nested scores
+@subsubsection Nested scores
It is possible to nest music inside markups, by adding a
@code{\score} block to a markup expression. Such a score must
Snippets: @lsrdir{Text,Text}
@node Page wrapping text
-@unnumberedsubsubsec Page wrapping text
+@subsubsection Page wrapping text
Whereas @code{\markup} is used to enter a non-breakable block of
text, @code{\markuplines} can be used at top-level to enter lines
@code{\markuplines}
@node Font selection
-@unnumberedsubsubsec Font selection
+@subsubsection Font selection
@cindex font selection
@cindex font magnification
@end menu
@node New dynamic marks
-@unnumberedsubsubsec New dynamic marks
+@subsubsection New dynamic marks
It is possible to print new dynamic marks or text that should be
aligned with dynamics. Use @code{make-dynamic-script} to create
@node Text and line spanners
-@unnumberedsubsubsec Text and line spanners
+@subsubsection Text and line spanners
Some performance indications, e.g., @i{rallentando} and
@i{accelerando} and @i{trills} are written as text and are
(optionally) a MIDI file which can be played. The first example
shows what a simple input text file looks like.
+To create sheet music, we write a text file that specifies the
+notation. For example, if we write:
+
@example
@{
c' e' g' e'
}
@end lilypond
-@warning{Every piece of LilyPond input needs to have
-@strong{@{ curly braces @}} placed around the input. The braces
+@warning{Notes and lyrics in LilyPond input must always be
+surrounded by @strong{@{ curly braces @}}. The braces
should also be surrounded by a space unless they are at the
beginning or end of a line to avoid ambiguities. The braces may
be omitted in some examples in this manual, but don't forget them
confusion to newcomers, so let us explain it in more detail.
LilyPond makes a sharp distinction between musical content and
-layout. The alteration (@notation{flat}, @notation{natural} or
+layout. The alteration (@notation{flat}, @notation{natural sign} or
@notation{sharp}) of a note is part of the pitch, and is therefore
musical content. Whether an accidental (a @emph{printed} flat,
natural or sharp sign) is printed in front of the corresponding
@subheading Simultaneous music expressions: single staff
To determine the number of staves in a piece, LilyPond looks at
-the first expression. If it is a single note, there is one staff;
-if there is a simultaneous expression, there is more than one
-staff.
+the beginning of the first expression. If is a single note, there
+is one staff; if there is a simultaneous expression, there is more
+than one staff.
@lilypond[verbatim,quote,ragged-right]
\relative c'' {
Music Glossary: @rglos{chord}.
-@notation{Chords} can be made by surrounding pitches with single
-angle brackets. Note that all the notes in a chord must have the
-same duration, and that duration is placed after the closing
-bracket.
+We saw earlier how notes can be combined into @notation{chords} by
+indicating they are simultaneous by enclosing them in double angle
+brackets. However, the normal way of indicating a chord is to
+surround the pitches with @emph{single} angle brackets. Note that
+all the notes in a chord must have the same duration, and that the
+duration is placed after the closing bracket.
@lilypond[verbatim,quote,ragged-right,fragment,relative=2]
r4 <c e g>4 <c f a>2
Think of chords as almost equivalent to single notes:
almost everything you can attach to a single note can be attached
-to a chord, and everything must go @emph{outside} the angle
-brackets. For example, you can combine markings like beams and
+to a chord, and everything must go @emph{outside} the angle
+brackets. For example, you can combine markings like beams and
ties with chords. They must be placed outside the angle brackets.
@lilypond[verbatim,quote,ragged-right,fragment,relative=2]
+
This chapter discusses how to modify output. LilyPond is extremely
configurable; virtually every fragment of output may be changed.
-TODO: This chapter is still under development and this version is
-not yet complete. Don't translate yet!
-
-
@menu
* Tweaking basics::
achieved.
In this section we cover the basic concepts required to understand
-tweaking. Later we give a variety of potted commands which can
+tweaking. Later we give a variety of ready-made commands which can
simply be copied to obtain the same effect in your own scores, and
at the same time we show how these commands may be constructed so
that you may learn how to develop your own tweaks.
properties associated with that particular staff, for example, its
name and its key signature, together with details of the engravers
which have been assigned to operate within that staff's context.
-Similarly, there are @code{Voice} objects, @code{Score} objects,
-@code{Lyric} objects, and objects to represent bar lines,
- note heads, ties, dynamics, etc, each with their own set of
-properties.
+Similarly, there are objects to hold the properties of all other
+contexts, such as @code{Voice} objects, @code{Score} objects,
+@code{Lyrics} objects, as well as objects to represent all
+notational elements such as bar lines,
+note heads, ties, dynamics, etc. Every object has its own set of
+property values.
Some types of object are given special names. Objects which
represent items of notation on the printed output such as
@headitem Object/property type
@tab Naming convention
@tab Example
-@item Contexts, Layout Objects
+@item Contexts
+ @tab Aaaa or AaaaAaaaAaaa
+ @tab Staff, GrandStaff
+@item Layout Objects
@tab Aaaa or AaaaAaaaAaaa
- @tab Staff, GrandStaff,
+ @tab Slur, NoteHead
@item Engravers
@tab Aaaa_aaa_engraver
@tab Clef_engraver, Note_heads_engraver
@c Maybe explain in a later iteration -td
The final tweaking command which is available is @code{\tweak}.
-It is not really a new command but a shorthand for an
-@code{\override} command which must be used in a few special
-circumstances. Again, we shall not discuss or use it here.
-You may find the details in
+This should be used to change the properties of objects which
+occur at the same musical moment, such as the notes within a
+chord. Using @code{\override} would affect all the notes
+within a chord, whereas @code{\tweak} affects just the following
+item in the input stream. You may find the details in
@ruser{Objects connected to the input}.
-@c Maybe explain in a later iteration -td
@node The Internals Reference manual
@section The Internals Reference manual
by extension, many other layout objects too.) Let's consider
each of these in turn.
-@c FIXME: is this what you meant?
-@c TODO Change all other headings like this
@subheading stencil
@cindex stencil property
when the object is created. The following table shows
the default numerical values for some of the commonest
outside-staff objects which are, by default, placed in the
-@code{Staff} Context.
+@code{Staff} or @code{Voice} contexts.
@multitable @columnfractions .3 .3 .3
@headitem Layout Object
@tab Priority
@tab Controls position of:
-@item @code{DynamicLineSpanner}
- @tab @code{ 250}
- @tab All dynamic markings
-@item @code{OttavaBracket}
- @tab @code{ 400}
- @tab Ottava brackets
-@item @code{TextScript}
- @tab @code{ 450}
+@item @code{MultiMeasureRestText}
+ @tab @code{450}
+ @tab Text over full-bar rests
+@item @code{TextScript}
+ @tab @code{450}
@tab Markup text
-@item @code{TextSpanner}
- @tab @code{ 350}
+@item @code{OttavaBracket}
+ @tab @code{400}
+ @tab Ottava brackets
+@item @code{TextSpanner}
+ @tab @code{350}
@tab Text spanners
+@item @code{DynamicLineSpanner}
+ @tab @code{250}
+ @tab All dynamic markings
+@item @code{VoltaBracketSpanner}
+ @tab @code{100}
+ @tab Volta brackets
+@item @code{TrillSpanner}
+ @tab @code{50}
+ @tab Spanning trills
@end multitable
-Here is an example showing the default placement of these.
+Here is an example showing the default placement of some of
+these.
@cindex text spanner
@funindex \startTextSpan
@multitable @columnfractions .3 .3
@headitem Layout Object @tab Priority
-@item @code{BarNumber} @tab @code{ 100}
-@item @code{MetronomeMark} @tab @code{1000}
@item @code{RehearsalMark} @tab @code{1500}
+@item @code{MetronomeMark} @tab @code{1000}
+@item @code{BarNumber} @tab @code{ 100}
@end multitable
If the default values of @code{outside-staff-priority} does not
like the ottava bracket to be placed below the text spanner in the
example above. All we need to do is to look up the priority of
@code{OttavaBracket} in the IR or in the tables above, and reduce
-it to a value lower than that of a @code{TextSpanner}:
+it to a value lower than that of a @code{TextSpanner}, remembering
+that @code{OttavaBracket} is created in the @code{Staff} context:
@lilypond[quote,fragment,ragged-right,verbatim,relative=1]
% Set details for later Text Spanner
% Place dynamics above staff
\dynamicUp
%Place following Ottava Bracket below Text Spanners
-\once \override OttavaBracket #'outside-staff-priority = #340
+\once \override Staff.OttavaBracket #'outside-staff-priority = #340
% Start Ottava Bracket
#(set-octavation 1)
c' \startTextSpan
@code{self-alignment-X}
@cindex self-alignment-X property
-This property aligns the object to the left, to the right, or
-centers it with respect to the parent object's reference point.
-It may be used with all objects which support the
-@code{self-alignment-interface}. In general these are objects
+This property can be used to align the object to the left, to
+the right, or to center it with respect to the parent object's
+reference point. It may be used with all objects which support
+the @code{self-alignment-interface}. In general these are objects
that contain text. The values are @code{LEFT}, @code{RIGHT}
-or @code{CENTER}. The movement is limited by the length of the
-object. Any numerical value between @code{-1} and @code{+1} may
-also be specified, where @code{-1} is left-aligned, @code{+1}
-is right-aligned, and numbers in between move the text
-progressively from left-aligned to right-aligned.
+or @code{CENTER}. Alternatively, a numerical value between
+@code{-1} and @code{+1} may be specified, where @code{-1} is
+left-aligned, @code{+1} is right-aligned, and numbers in between
+move the text progressively from left-aligned to right-aligned.
+Numerical values greater than @code{1} may be specified to move
+the text even further to the left, or less than @code{-1} to
+move the text even further to the right. A change of @code{1}
+in the value corresponds to a movement of half the text's length.
@item
@code{extra-spacing-width}
of beams, slurs, and tuplets. It takes a pair of numbers
giving the position of the left and right ends of the beam, slur,
etc. relative to the center line of the staff. Units are
-staff-spaces.
+staff-spaces. Note, though, that slurs and phrasing slurs cannot
+be repositioned by arbitrarily large amounts. LilyPond first
+generates a list of possible positions for the slur and by default
+finds the slur that @qq{looks best}. If the @code{positions}
+property has been overridden the slur that is closest to the
+requested positions is selected from the list.
@end table
Objects do not all have all of these properties in general.
Let's now see how the properties in the previous section can
help to resolve overlapping notation.
-@subheading padding property
+@c FIXME: formatting
+@subheading @code{padding}
@cindex padding property
The @code{padding} property can be set to increase
@end lilypond
Note in the second example how important it is to figure out what
-context handles a certain object. Since the @code{MetronomeMark} object
+context handles a certain object. Since the @code{MetronomeMark}
+object
is handled in the @code{Score} context, property changes in the
@code{Voice} context will not be noticed. For more details, see
@ruser{Constructing a tweak}.
-@subheading left-padding and right-padding properties
+If the @code{padding} property of an object is increased when that
+object is in a stack of objects being positioned according to
+their @code{outside-staff-priority}, then that object and all
+objects outside it are moved.
+
+
+@subheading @code{left-padding} and @code{right-padding}
@cindex left-padding property
@cindex right-padding property
+
@end menu
@node Setting simple songs
-@unnumberedsubsubsec Setting simple songs
+@subsubsection Setting simple songs
@cindex \addlyrics
@node Entering lyrics
-@unnumberedsubsubsec Entering lyrics
+@subsubsection Entering lyrics
@cindex lyrics
@funindex \lyricmode
@end menu
@node Automatic syllable durations
-@unnumberedsubsubsec Automatic syllable durations
+@subsubsection Automatic syllable durations
@cindex automatic syllable durations
@cindex lyrics and melodies
@end example
@node Another way of entering lyrics
-@unnumberedsubsubsec Another way of entering lyrics
+@subsubsection Another way of entering lyrics
Lyrics can also be entered without @code{\addlyrics} or
@code{\lyricsto}. In this case,
@node Assigning more than one syllable to a single note
-@unnumberedsubsubsec Assigning more than one syllable to a single note
+@subsubsection Assigning more than one syllable to a single note
@funindex _
@node More than one note on a single syllable
-@unnumberedsubsubsec More than one note on a single syllable
+@subsubsection More than one note on a single syllable
@cindex melisma
@cindex melismata
inserted by hand.
@node Extenders and hyphens
-@unnumberedsubsubsec Extenders and hyphens
+@subsubsection Extenders and hyphens
@cindex melisma
@cindex extender
@end menu
@node Working with lyrics and variables
-@unnumberedsubsubsec Working with lyrics and variables
+@subsubsection Working with lyrics and variables
@cindex lyrics, variables
@node Lyrics to multiple notes of a melisma
-@unnumberedsubsubsec Lyrics to multiple notes of a melisma
+@subsubsection Lyrics to multiple notes of a melisma
One possibility is that the text has a melisma in one stanza, but
multiple syllables in another one. One solution is to make the faster
@node Divisi lyrics
-@unnumberedsubsubsec Divisi lyrics
+@subsubsection Divisi lyrics
You can display alternate (or divisi) lyrics by naming voice
contexts and attaching lyrics to those specific contexts.
@node Switching the melody associated with a lyrics line
-@unnumberedsubsubsec Switching the melody associated with a lyrics line
+@subsubsection Switching the melody associated with a lyrics line
More complex variations in text underlay are possible. It is possible
to switch the melody for a line of lyrics during the text. This is
@node Lyrics independent of notes
-@unnumberedsubsubsec Lyrics independent of notes
+@subsubsection Lyrics independent of notes
In some complex vocal music, it may be desirable to place
lyrics completely independently of notes. Music defined
@end menu
@node Spacing lyrics
-@unnumberedsubsubsec Spacing lyrics
+@subsubsection Spacing lyrics
@cindex Spacing lyrics
@cindex Lyrics, increasing space between
@node Adding stanza numbers
-@unnumberedsubsubsec Adding stanza numbers
+@subsubsection Adding stanza numbers
@cindex stanza number
@node Adding dynamics marks
-@unnumberedsubsubsec Adding dynamics marks
+@subsubsection Adding dynamics marks
Stanzas differing in loudness may be indicated by putting a
dynamics mark before each stanza. In Lilypond, everthing coming in
@end lilypond
@node Adding singer names
-@unnumberedsubsubsec Adding singer names
+@subsubsection Adding singer names
@cindex singer name
@cindex name of singer
@node Printing stanzas at the end
-@unnumberedsubsubsec Printing stanzas at the end
+@subsubsection Printing stanzas at the end
Sometimes it is appropriate to have one stanza set
to the music, and the rest added in verse form at
@node Printing stanzas at the end in multiple columns
-@unnumberedsubsubsec Printing stanzas at the end in multiple columns
+@subsubsection Printing stanzas at the end in multiple columns
When a piece of music has many verses, they are often printed in
multiple columns across the page. An outdented verse number often
to this scheme construct. ie
\set Staff.instrumentName = #"cello"
+* Examples should end with a complete bar if possible.
+
* If possible, only write one bar per line. The notes on each
line should be an independent line -- tweaks should occur on
their own line if possible.
PACKAGE_NAME=LilyPond
MAJOR_VERSION=2
MINOR_VERSION=11
-PATCH_LEVEL=38
+PATCH_LEVEL=39
MY_PATCH_LEVEL=
doc_dirs = ['input', 'Documentation', outdir]
target_pattern = os.path.join (outdir, '%s-root')
+# these redirection pages allow to go back to the documentation index
+# from HTML manuals/snippets page
static_files = {
os.path.join (outdir, 'index.html'):
- '''<META HTTP-EQUIV="refresh" content="0;URL=Documentation/index.html">
+ '''<META HTTP-EQUIV="refresh" content="0;URL=Documentation/index.html">
<html><body>Redirecting to the documentation index...</body></html>\n''',
os.path.join (outdir, 'VERSION'):
- package_version + '\n' }
+ package_version + '\n',
+ os.path.join ('input', 'lsr', outdir, 'index.html'):
+ '''<META HTTP-EQUIV="refresh" content="0;URL=../../index.html">
+<html><body>Redirecting to the documentation index...</body></html>\n'''
+ }
import langdefs
-# ugly hack: the following overwrites HTML Info dir with a link to
-# the (more useful) documentation index
for l in langdefs.LANGUAGES:
- static_files[os.path.join ('Documentation/user', outdir, l.file_name ('index', '.html'))] = \
+ static_files[os.path.join ('Documentation', 'user', outdir, l.file_name ('index', '.html'))] = \
'<META HTTP-EQUIV="refresh" content="0;URL=../' + l.file_name ('index', '.html') + \
'">\n<html><body>Redirecting to the documentation index...</body></html>\n'
dirs, symlinks, files = mirrortree.walk_tree (
tree_roots = doc_dirs,
process_dirs = outdir,
- exclude_dirs = '(^|/)(' + '|'.join ([l.code for l in langdefs.LANGUAGES]) + r'|po|out|\w*?-root)(/|$)',
+ exclude_dirs = '(^|/)(' + '|'.join ([l.code for l in langdefs.LANGUAGES]) + r'|po|out|.*?[.]t2d|\w*?-root)(/|$)',
find_files = r'.*?\.(?:midi|html|pdf|png|txt|ly|signature)$|VERSION',
- exclude_files = r'lily-[0-9a-f]+.*\.pdf')
+ exclude_files = r'lily-[0-9a-f]+.*\.(pdf|txt)')
# actual mirrorring stuff
html_files = []
--- /dev/null
+\header {
+ texidoc = "The ligature bracket right-end is not affected by other voices."
+}
+
+\version "2.11.38"
+<<
+ \new Staff {\[b2 b\] | \[b b\] }
+ \new Staff {b2 b | b4 b b b }
+>>
<?xml version="1.0"?>
-<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 0.6 Partwise//EN" "http://www.musicxml.org/dtds/partwise.dtd">
-<score-partwise>
- <work> <work-title>/home/reinhold/lilypond-dev-files/07_nokey.xml</work-title></work>
- <identification>
- <rights>Unknown</rights>
- <encoding>
- <software>Rosegarden-4</software>
- </encoding>
- </identification>
+<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 2.0 Partwise//EN" "http://www.musicxml.org/dtds/partwise.dtd">
+<score-partwise version="2.0">
+ <work><work-title>No key or clef given</work-title></work>
+ <identification/>
<part-list>
<score-part id="0">
- <part-name>NoClef Test</part-name>
- <score-instrument id="#1">
- <instrument-name>0</instrument-name>
- </score-instrument>
- <midi-instrument id="#1">
- <midi-channel>1</midi-channel>
- <midi-program>1</midi-program>
- </midi-instrument>
+ <part-name></part-name>
</score-part>
</part-list>
<part id="0">
<measure number="1">
<attributes>
- <divisions>960</divisions>
+ <divisions>1</divisions>
<time>
<beats>4</beats>
<beat-type>4</beat-type>
<step>C</step>
<octave>4</octave>
</pitch>
- <duration>3840</duration>
+ <duration>4</duration>
<voice>1</voice>
<type>whole</type>
</note>
</measure>
-
<measure number="2">
<note>
<pitch>
<step>C</step>
<octave>4</octave>
</pitch>
- <duration>3840</duration>
+ <duration>4</duration>
<voice>1</voice>
<type>whole</type>
</note>
<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
-<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 0.6b Partwise//EN"
+<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 2.0 Partwise//EN"
"http://www.musicxml.org/dtds/partwise.dtd">
-<score-partwise>
- <identification>
- <encoding>
- <software>/usr/bin/vi</software>
- <encoding-date>2007-01-22</encoding-date>
- </encoding>
- </identification>
+<score-partwise version="2.0">
+ <work><work-title>No time signature given</work-title></work>
+ <identification/>
<part-list>
<score-part id="P1">
- <part-name>MIDI Track 1</part-name>
+ <part-name></part-name>
</score-part>
</part-list>
<part id="P1">
<measure number="1">
<attributes>
- <divisions>96</divisions>
+ <divisions>1</divisions>
<key><fifths>0</fifths></key>
<staves>2</staves>
<clef number="1"><sign>G</sign><line>2</line></clef>
</attributes>
<note>
<pitch><step>F</step><octave>4</octave></pitch>
- <duration>384</duration>
+ <duration>4</duration>
<voice>1</voice>
<type>whole</type>
<staff>1</staff>
<backup><duration>384</duration></backup>
<note>
<pitch><step>B</step><octave>2</octave></pitch>
- <duration>384</duration>
+ <duration>4</duration>
<voice>2</voice>
<type>whole</type>
<staff>2</staff>
<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 0.6b Partwise//EN"
"http://www.musicxml.org/dtds/partwise.dtd">
<score-partwise>
- <identification>
- <encoding>
- <software>/usr/bin/vi</software>
- <encoding-date>2007-02-02</encoding-date>
- </encoding>
- </identification>
+ <work><work-title>A tie</work-title></work>
+ <identification/>
<part-list>
- <score-part id="P1"><part-name>MIDI Track 1</part-name></score-part>
+ <score-part id="P1"><part-name></part-name></score-part>
</part-list>
<part id="P1">
<measure number="1">
<attributes>
- <divisions>96</divisions>
+ <divisions>1</divisions>
<key><fifths>0</fifths></key>
<time><beats>4</beats><beat-type>4</beat-type></time>
<staves>1</staves>
</attributes>
<note>
<pitch><step>F</step><octave>4</octave></pitch>
- <duration>384</duration>
+ <duration>4</duration>
<tie type="start"/>
<voice>1</voice>
<type>whole</type>
<measure number="2">
<note release="-684">
<pitch><step>F</step><octave>4</octave></pitch>
- <duration>384</duration>
+ <duration>4</duration>
<tie type="stop"/>
<voice>1</voice>
<type>whole</type>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 2.0 Partwise//EN"
- "http://www.musicxml.org/dtds/partwise.dtd">
+ "http://www.musicxml.org/dtds/partwise.dtd">
<score-partwise version="2.0">
- <movement-title>All MusicXML Notations</movement-title>
+ <movement-title>MusicXML notations (attached to note)</movement-title>
<identification/>
<part-list>
<score-part id="P1">
</barline>
</measure>
- <!-- General tests: multiple notations, directions, pedal spanners, etc. -->
+ <!-- Dynamics, attached to notes by putting them inside <notations> tags -->
<measure number="22">
- <direction placement="below">
- <direction-type>
- <pedal line="no" relative-x="-9" type="start"/>
- </direction-type>
- </direction>
<note>
<pitch>
- <step>G</step>
- <octave>4</octave>
+ <step>C</step><octave>5</octave>
</pitch>
<duration>1</duration>
<voice>1</voice>
<type>quarter</type>
+ <notations>
+ <dynamics><f/></dynamics>
+ </notations>
+ <lyric number="1"><text>f</text></lyric>
</note>
- <direction placement="below">
- <direction-type>
- <pedal line="no" type="stop"/>
- </direction-type>
- </direction>
<note>
<pitch>
- <step>G</step>
- <octave>4</octave>
+ <step>C</step><octave>5</octave>
+ </pitch>
+ <duration>1</duration>
+ <voice>1</voice>
+ <type>quarter</type>
+ <notations>
+ <dynamics><ppp/></dynamics>
+ </notations>
+ <lyric number="1"><text>ppp</text></lyric>
+ </note>
+ <note>
+ <pitch>
+ <step>C</step><octave>5</octave>
+ </pitch>
+ <duration>1</duration>
+ <voice>1</voice>
+ <type>quarter</type>
+ <notations>
+ <dynamics><sfp/></dynamics>
+ </notations>
+ <lyric number="1"><text>sfp</text></lyric>
+ </note>
+ <note>
+ <pitch>
+ <step>C</step><octave>5</octave>
</pitch>
<duration>1</duration>
<voice>1</voice>
<type>quarter</type>
+ <notations>
+ <dynamics><other-dynamics>sfffz</other-dynamics></dynamics>
+ </notations>
+ <lyric number="1"><text>Oth.dyn.</text></lyric>
</note>
+ </measure>
+
+ <!-- General tests: multiple notations, directions, etc. -->
+ <measure number="23">
<note>
<pitch>
<step>G</step>
</notations>
<lyric number="1"><text>ab./bel./bel.</text></lyric>
</note>
+ <note>
+ <rest/>
+ <duration>2</duration>
+ <voice>1</voice>
+ <type>half</type>
+ </note>
<barline location="right">
<bar-style>light-heavy</bar-style>
</barline>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>\r
+<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 2.0 Partwise//EN"\r
+ "http://www.musicxml.org/dtds/partwise.dtd">\r
+<score-partwise version="2.0">\r
+ <movement-title>MusicXML directions (attached to staff)</movement-title>\r
+ <identification/>\r
+ <defaults/>\r
+ <part-list>\r
+ <score-part id="P1">\r
+ <part-name print-object="no">MusicXML Part</part-name>\r
+ </score-part>\r
+ </part-list>\r
+ <!--=========================================================-->\r
+ <part id="P1">\r
+ <!-- Direction type can contain the following child types:\r
+ rehearsal+ | segno+ | words+ |\r
+ coda+ | wedge | dynamics+ | dashes | bracket | pedal | \r
+ metronome | octave-shift | harp-pedals | damp | \r
+ damp-all | eyeglasses | scordatura | image |\r
+ accordion-registration | other-direction -->\r
+ <!-- Rehearsal marks -->\r
+ <measure number="1">\r
+ <attributes>\r
+ <divisions>1</divisions>\r
+ <key>\r
+ <fifths>0</fifths>\r
+ <mode>major</mode>\r
+ </key>\r
+ <time symbol="common">\r
+ <beats>4</beats>\r
+ <beat-type>4</beat-type>\r
+ </time>\r
+ <clef>\r
+ <sign>G</sign>\r
+ <line>2</line>\r
+ </clef>\r
+ </attributes>\r
+ <sound tempo="120"/>\r
+ <direction placement="below">\r
+ <direction-type>\r
+ <rehearsal>A</rehearsal>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>reh.A (def=sq.)</text></lyric>\r
+ </note>\r
+ <direction placement="above">\r
+ <direction-type>\r
+ <rehearsal enclosure="none">B</rehearsal>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>reh.B (none)</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <rehearsal enclosure="square">Test</rehearsal>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>reh.Test (sq.)</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <rehearsal enclosure="circle">Crc</rehearsal>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>reh.Crc (crc.)</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <!-- Segno, Coda, Words (extra unit test for formatting!), Eyeglasses -->\r
+ <measure number="2">\r
+ <direction>\r
+ <direction-type>\r
+ <segno/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Segno</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <coda/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Coda</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <words>words</words>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Words</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <eyeglasses/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Eyegl.</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <!-- Dynamics: p | pp | ppp | pppp | ppppp | pppppp |\r
+ f | ff | fff | ffff | fffff | ffffff | mp | mf | sf |\r
+ sfp | sfpp | fp | rf | rfz | sfz | sffz | fz | \r
+ other-dynamics -->\r
+ <measure number="3">\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><p/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>p</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><pp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>pp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><ppp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>ppp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><pppp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>pppp</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="4">\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><ppppp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>ppppp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><pppppp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>pppppp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><f/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>f</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><ff/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>ff</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="5">\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><fff/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>fff</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><ffff/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>ffff</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><fffff/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>fffff</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><ffffff/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>ffffff</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="6">\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><mp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>mp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><mf/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>mf</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><sf/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>sf</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><sfp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>sfp</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="7">\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><sfpp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>sfpp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><fp/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>fp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><rf/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>rf</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><rfz/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>rfz</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="8">\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><sfz/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>sfz</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><sffz/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>sffz</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><fz/></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>fz</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dynamics><other-dynamics>abc-ffz</other-dynamics></dynamics>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>abc-ffz (oth.)</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <!-- Spanners (there is another unit test for testing the various options):\r
+ wedge, dashes, bracket, pedal, octave-shift -->\r
+ <measure number="9">\r
+ <direction>\r
+ <direction-type>\r
+ <wedge type="crescendo"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>begin</syllabic><text>hairpin</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <wedge type="stop"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>end</syllabic><text>cresc</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dashes type="start"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>begin</syllabic><text>dash</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <dashes type="stop"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>end</syllabic><text>es</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="10">\r
+ <direction>\r
+ <direction-type>\r
+ <bracket type="start" line-end="none"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>begin</syllabic><text>bra</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <bracket type="stop" line-end="none"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>end</syllabic><text>cket</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <octave-shift type="up"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>begin</syllabic><text>oct.</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <octave-shift type="stop"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>end</syllabic><text>shift</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="11">\r
+ <direction>\r
+ <direction-type>\r
+ <pedal type="start"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>begin</syllabic><text>pedal</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <pedal type="change"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>continue</syllabic><text>change</text></lyric>\r
+ </note>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <pedal type="stop"/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>end</syllabic><text>mark</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <!-- metronome, harp-pedals, damp, damp-all, scordatura, accordion-registration -->\r
+ <measure number="12">\r
+ <direction>\r
+ <direction-type>\r
+ <metronome><beat-unit>quarter</beat-unit><per-minute>60</per-minute></metronome>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Metr.</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <harp-pedals>\r
+ <pedal-tuning>\r
+ <pedal-step>D</pedal-step>\r
+ <pedal-alter>0</pedal-alter>\r
+ </pedal-tuning>\r
+ <pedal-tuning>\r
+ <pedal-step>C</pedal-step>\r
+ <pedal-alter>-1</pedal-alter>\r
+ </pedal-tuning>\r
+ <pedal-tuning>\r
+ <pedal-step>B</pedal-step>\r
+ <pedal-alter>-1</pedal-alter>\r
+ </pedal-tuning>\r
+ <pedal-tuning>\r
+ <pedal-step>E</pedal-step>\r
+ <pedal-alter>0</pedal-alter>\r
+ </pedal-tuning>\r
+ <pedal-tuning>\r
+ <pedal-step>F</pedal-step>\r
+ <pedal-alter>0</pedal-alter>\r
+ </pedal-tuning>\r
+ <pedal-tuning>\r
+ <pedal-step>G</pedal-step>\r
+ <pedal-alter>1</pedal-alter>\r
+ </pedal-tuning>\r
+ <pedal-tuning>\r
+ <pedal-step>A</pedal-step>\r
+ <pedal-alter>-1</pedal-alter>\r
+ </pedal-tuning>\r
+ </harp-pedals>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Harp ped.</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <damp/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Damp</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <damp-all/>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Damp all</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="13">\r
+ <direction>\r
+ <direction-type>\r
+ <scordatura>\r
+ <accord string="0"><tuning-step>C</tuning-step><tuning-octave>3</tuning-octave></accord>\r
+ <accord string="1"><tuning-step>G</tuning-step><tuning-octave>5</tuning-octave></accord>\r
+ <accord string="2"><tuning-step>E</tuning-step><tuning-octave>5</tuning-octave></accord>\r
+ </scordatura>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Scord.</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>2</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>Accordion reg.</text></lyric>\r
+ </note>\r
+ <note>\r
+ <rest/>\r
+ <duration>2</duration>\r
+ <voice>1</voice>\r
+ <type>half</type>\r
+ </note>\r
+ <barline location="right">\r
+ <bar-style>light-light</bar-style>\r
+ </barline>\r
+ </measure>\r
+ <!-- Other issues: Multiple direction-type elements: "subito p", ppp<fff -->\r
+ <measure number="14">\r
+ <direction placement="below">\r
+ <direction-type>\r
+ <words default-y="-80" font-family="Times New Roman" font-size="10.25" font-style="italic">subito</words>\r
+ </direction-type>\r
+ <direction-type>\r
+ <words default-y="-80" font-family="Times New Roman" font-size="10.25">Â </words>\r
+ </direction-type>\r
+ <direction-type>\r
+ <dynamics default-y="-80">\r
+ <p/>\r
+ </dynamics>\r
+ </direction-type>\r
+ <offset>2</offset>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>subp</text></lyric>\r
+ </note>\r
+ <direction placement="below">\r
+ <direction-type>\r
+ <dynamics><ppp/></dynamics>\r
+ </direction-type>\r
+ <direction-type>\r
+ <wedge type="crescendo"/>\r
+ </direction-type>\r
+ <offset>2</offset>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>begin</syllabic><text>ppp cresc</text></lyric>\r
+ </note>\r
+ <direction placement="below">\r
+ <direction-type>\r
+ <wedge type="stop"/>\r
+ </direction-type>\r
+ <direction-type>\r
+ <dynamics><fff/></dynamics>\r
+ </direction-type>\r
+ <offset>2</offset>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><syllabic>end</syllabic><text>to fff</text></lyric>\r
+ </note>\r
+ <note>\r
+ <rest/>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>subp</text></lyric>\r
+ </note>\r
+ <barline location="right">\r
+ <bar-style>light-heavy</bar-style>\r
+ </barline>\r
+ </measure>\r
+ <!--=======================================================-->\r
+ </part>\r
+ <!--=========================================================-->\r
+</score-partwise>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 1.0 Partwise//EN"\r
- "http://www.musicxml.org/dtds/partwise.dtd">\r
-<score-partwise>\r
- <movement-title>Finale Dynamics Test</movement-title>\r
- <identification>\r
- <creator type="composer">Reinhold Kainhofer</creator>\r
- <rights>Public Domain</rights>\r
- <encoding>\r
- <software>Finale 2007 for Windows</software>\r
- <software>Dolet Light for Finale 2007</software>\r
- <encoding-date>2007-09-02</encoding-date>\r
- </encoding>\r
- </identification>\r
- <part-list>\r
- <score-part id="P1">\r
- <part-name>MusicXML Part</part-name>\r
- <score-instrument id="P1-I1">\r
- <instrument-name>Grand Piano</instrument-name>\r
- </score-instrument>\r
- <midi-instrument id="P1-I1">\r
- <midi-channel>1</midi-channel>\r
- <midi-program>1</midi-program>\r
- </midi-instrument>\r
- </score-part>\r
- </part-list>\r
- <!--=========================================================-->\r
- <part id="P1">\r
- <measure number="1">\r
- <attributes>\r
- <divisions>8</divisions>\r
- <key>\r
- <fifths>0</fifths>\r
- <mode>major</mode>\r
- </key>\r
- <time symbol="common">\r
- <beats>4</beats>\r
- <beat-type>4</beat-type>\r
- </time>\r
- <clef>\r
- <sign>G</sign>\r
- <line>2</line>\r
- </clef>\r
- </attributes>\r
- <sound tempo="120"/>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80" relative-x="-3">\r
- <ffff/>\r
- </dynamics>\r
- </direction-type>\r
- <sound dynamics="141"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <sound dynamics="127"/>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- <notations>\r
- <dynamics default-y="-80" placement="below">\r
- <fff/>\r
- </dynamics>\r
- </notations>\r
- </note>\r
- <sound dynamics="112"/>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- <notations>\r
- <dynamics default-y="-80" placement="below">\r
- <ff/>\r
- </dynamics>\r
- </notations>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <f/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>2</offset>\r
- <sound dynamics="98"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- </measure>\r
- <!--=======================================================-->\r
- <measure number="2">\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <mf/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>1</offset>\r
- <sound dynamics="83"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <sound dynamics="69"/>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- <notations>\r
- <dynamics default-y="-80" placement="below">\r
- <mp/>\r
- </dynamics>\r
- </notations>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <p/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>2</offset>\r
- <sound dynamics="54"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <pp/>\r
- </dynamics>\r
- </direction-type>\r
- <sound dynamics="40"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- </measure>\r
- <!--=======================================================-->\r
- <measure number="3">\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <ppp/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>1</offset>\r
- <sound dynamics="26"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <pppp/>\r
- </dynamics>\r
- </direction-type>\r
- <sound dynamics="11"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <fp/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>2</offset>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <fz/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>2</offset>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- </measure>\r
- <!--=======================================================-->\r
- <measure number="4">\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <sf/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>1</offset>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <sfz/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>1</offset>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <sffz/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>2</offset>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <direction placement="below">\r
- <direction-type>\r
- <words default-y="-80" font-family="Times New Roman" font-size="10.25" font-style="italic">subito</words>\r
- </direction-type>\r
- <direction-type>\r
- <words default-y="-80" font-family="Times New Roman" font-size="10.25">Â </words>\r
- </direction-type>\r
- <direction-type>\r
- <dynamics default-y="-80">\r
- <p/>\r
- </dynamics>\r
- </direction-type>\r
- <offset>2</offset>\r
- <sound dynamics="54"/>\r
- </direction>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- </measure>\r
- <!--=======================================================-->\r
- <measure number="5">\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <note>\r
- <pitch>\r
- <step>G</step>\r
- <octave>4</octave>\r
- </pitch>\r
- <duration>8</duration>\r
- <voice>1</voice>\r
- <type>quarter</type>\r
- <stem>up</stem>\r
- </note>\r
- <barline location="right">\r
- <bar-style>light-heavy</bar-style>\r
- </barline>\r
- </measure>\r
- </part>\r
- <!--=========================================================-->\r
-</score-partwise>\r
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>\r
+<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 2.0 Partwise//EN"\r
+ "http://www.musicxml.org/dtds/partwise.dtd">\r
+<score-partwise version="2.0">\r
+ <movement-title>Accordion registrations</movement-title>\r
+ <identification/>\r
+ <defaults/>\r
+ <part-list>\r
+ <score-part id="P1">\r
+ <part-name></part-name>\r
+ </score-part>\r
+ </part-list>\r
+ <!--=========================================================-->\r
+ <part id="P1">\r
+ <!-- Direction type can contain the following child types:\r
+ rehearsal+ | segno+ | words+ |\r
+ coda+ | wedge | dynamics+ | dashes | bracket | pedal | \r
+ metronome | octave-shift | harp-pedals | damp | \r
+ damp-all | eyeglasses | scordatura | image |\r
+ accordion-registration | other-direction -->\r
+ <!-- Rehearsal marks -->\r
+ <measure number="1">\r
+ <attributes>\r
+ <divisions>1</divisions>\r
+ <key>\r
+ <fifths>0</fifths>\r
+ <mode>major</mode>\r
+ </key>\r
+ <time symbol="common">\r
+ <beats>4</beats>\r
+ <beat-type>4</beat-type>\r
+ </time>\r
+ <clef>\r
+ <sign>G</sign>\r
+ <line>2</line>\r
+ </clef>\r
+ </attributes>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/0/1</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-middle>1</accordion-middle>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/1/0</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-middle>1</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/1/1</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-middle>2</accordion-middle>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/2/0</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="2">\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-middle>2</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/2/1</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-middle>3</accordion-middle>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/3/0</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-middle>3</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>0/3/1</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/0/1</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="3">\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/0/0</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>1</accordion-middle>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/1/0</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>1</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/1/1</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>2</accordion-middle>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/2/0</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="4">\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>2</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/2/1</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>3</accordion-middle>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/3/0</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>3</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>1/3/1</text></lyric>\r
+ </note>\r
+ <!-- Special cases: No accordion-(high|middle|low) given, empty middle, \r
+ middle with invalid value, middle with 0 -->\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>empty</text></lyric>\r
+ </note>\r
+ </measure>\r
+ <measure number="5">\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle/>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>empty M</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>test</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>inval.M</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>0</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>M=0</text></lyric>\r
+ </note>\r
+ <direction>\r
+ <direction-type>\r
+ <accordion-registration>\r
+ <accordion-high/>\r
+ <accordion-middle>5</accordion-middle>\r
+ <accordion-low/>\r
+ </accordion-registration>\r
+ </direction-type>\r
+ </direction>\r
+ <note>\r
+ <pitch><step>C</step><octave>4</octave></pitch>\r
+ <duration>1</duration>\r
+ <voice>1</voice>\r
+ <type>quarter</type>\r
+ <lyric number="1"><text>M=5</text></lyric>\r
+ </note>\r
+ \r
+ <barline location="right">\r
+ <bar-style>light-heavy</bar-style>\r
+ </barline>\r
+ </measure>\r
+ <!--=======================================================-->\r
+ </part>\r
+ <!--=========================================================-->\r
+</score-partwise>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE score-partwise PUBLIC
- "-//Recordare//DTD MusicXML 1.0 Partwise//EN"
- "http://www.musicxml.org/dtds/partwise.dtd">
-
-<score-partwise>
- <work>
- </work>
-
- <identification>
- <encoding>
- <software>NoteEdit</software>
- </encoding>
- </identification>
-
- <part-list>
- <score-part id="P1">
- <part-name>Staff 1</part-name>
- <score-instrument id="P1-I1">
- <instrument-name>Klavier 1</instrument-name>
- </score-instrument>
- <midi-instrument id="P1-I1">
- <midi-channel>1</midi-channel>
- <midi-program>1</midi-program>
- </midi-instrument>
- </score-part>
- </part-list>
-
- <part id="P1">
- <measure number="1">
- <attributes>
- <divisions>1</divisions>
- <key>
- <fifths>-1</fifths>
- </key>
- <time>
- <beats>4</beats>
- <beat-type>4</beat-type>
- </time>
- <clef>
- <sign>G</sign>
- <line>2</line>
- </clef>
- </attributes>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <mf/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <ppp/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <pp/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <p/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- </measure>
- <measure number="2">
- <direction placement="above">
- <direction-type>
- <dynamics>
- <mp/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <mf/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <f/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <direction placement="above">
- <direction-type>
- <dynamics>
- <ff/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- </measure>
- <measure number="3">
- <direction placement="above">
- <direction-type>
- <dynamics>
- <fff/>
- </dynamics>
- </direction-type>
- </direction>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- <note>
- <pitch>
- <step>G</step>
- <octave>4</octave>
- </pitch>
- <duration>1</duration>
- <voice>1</voice>
- <type>quarter</type>
- <stem>up</stem>
- </note>
- </measure>
- </part>
-</score-partwise>
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE score-partwise PUBLIC
-"-//Recordare//DTD MusicXML 1.0 Partwise//EN"
-"http://www.musicxml.org/dtds/partwise.dtd">
-<score-partwise>
-<work>
-<work-title>JScore_Dynamics_Test</work-title>
-</work>
-<identification>
-<creator type="composer">Reinhold Kainhofer</creator>
-<encoding>
-<software>JMSL's MusicXMLWriter by Nick Didkovsky. Java Music Specification Language by Nick Didkovsky and Phil Burk, (c) 2003 Nick Didkovsky, Phil Burk. Available from: http://www.algomusic.com</software>
-</encoding>
-</identification>
-<part-list>
-<score-part id="P1" >
-<part-name>Voice 1</part-name>
-</score-part>
-</part-list>
-<part id="P1" >
-<measure number="1" >
-<attributes>
-<divisions>960</divisions>
-<key><fifths>0</fifths></key>
-<time><beats>4</beats><beat-type>4</beat-type></time>
-<clef><sign>G</sign><line>2</line></clef>
-</attributes>
-<direction placement="above">
-<direction-type>
-<metronome parentheses="yes" relative-y="18">
-<beat-unit>quarter</beat-unit>
-<per-minute>60</per-minute>
-</metronome>
-</direction-type>
-<offset>72</offset>
-<sound tempo="60" />
-</direction>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<ppp />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<pp />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<p />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<mp />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-</measure>
-<measure number="2" >
-<attributes>
-<divisions>960</divisions>
-<key><fifths>0</fifths></key>
-<time><beats>4</beats><beat-type>4</beat-type></time>
-<clef><sign>G</sign><line>2</line></clef>
-</attributes>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<mf />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<f />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<ff />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<direction placement="below" >
-<direction-type>
-<dynamics relative-y="-6" >
-<fff />
-</dynamics>
-</direction-type>
-<staff>1</staff>
-</direction>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-</measure>
-<measure number="3" >
-<attributes>
-<divisions>960</divisions>
-<key><fifths>0</fifths></key>
-<time><beats>4</beats><beat-type>4</beat-type></time>
-<clef><sign>G</sign><line>2</line></clef>
-</attributes>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-<note>
-<pitch>
-<step>G</step>
-<octave>4</octave>
-</pitch>
-<duration>960</duration>
-<voice>1</voice>
-<type>quarter</type>
-<notations>
-</notations>
-</note>
-</measure>
-<measure number="4" >
-<attributes>
-<divisions>960</divisions>
-<key><fifths>0</fifths></key>
-<time><beats>4</beats><beat-type>4</beat-type></time>
-<clef><sign>G</sign><line>2</line></clef>
-</attributes>
-</measure>
-</part>
-</score-partwise>
</part-list>\r
<!--=========================================================-->\r
<part id="P1">\r
+ <!-- Tested spanners: tuplet, slur(solid, dashed), wedge (cresc, dim),\r
+ wavy-line, octave-shift (8va,8vb,15ma,15mb), bracket (solid, \r
+ dashed up/down, dashes, glissando (wavy), slide (solid), \r
+ pedal (down,up,change; line/Ped*) -->\r
<measure number="1">\r
<attributes>\r
<divisions>24</divisions>\r
<?xml version="1.0" encoding="UTF-8"?>\r
-<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 1.0 Partwise//EN"\r
+<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 2.0 Partwise//EN"\r
"http://www.musicxml.org/dtds/partwise.dtd">\r
-<score-partwise>\r
- <movement-title>Finale "Quoted" test</movement-title>\r
+<score-partwise version="2.0">\r
+ <movement-title>"Quotes" in header fields</movement-title>\r
<identification>\r
- <creator type="composer">Reinhold "Tester" Kainhofer</creator>\r
+ <creator type="composer">Some "Tester" Name</creator>\r
<rights>Free for anyone ("Public Domain")</rights>\r
<encoding>\r
- <software>Finale 2007 for Windows</software>\r
- <software>Dolet Light for Finale 2007</software>\r
- <encoding-date>2007-09-01</encoding-date>\r
+ <software>"Hand-crafted" MusicXML file</software>\r
+ <encoding-date>2008-02-06</encoding-date>\r
</encoding>\r
</identification>\r
<part-list>\r
<score-part id="P1">\r
- <part-name>MusicXML Part</part-name>\r
- <score-instrument id="P1-I1">\r
- <instrument-name>Grand Piano</instrument-name>\r
- </score-instrument>\r
- <midi-instrument id="P1-I1">\r
- <midi-channel>1</midi-channel>\r
- <midi-program>1</midi-program>\r
- </midi-instrument>\r
+ <part-name>Staff "Test"</part-name>\r
</score-part>\r
</part-list>\r
<!--=========================================================-->\r
<part id="P1">\r
<measure number="1">\r
- <attributes>\r
- <divisions>1</divisions>\r
- <key>\r
- <fifths>0</fifths>\r
- <mode>major</mode>\r
- </key>\r
- <time symbol="common">\r
- <beats>4</beats>\r
- <beat-type>4</beat-type>\r
- </time>\r
- <clef>\r
- <sign>G</sign>\r
- <line>2</line>\r
- </clef>\r
- </attributes>\r
- <sound tempo="120"/>\r
<note>\r
<rest/>\r
<duration>4</duration>\r
<voice>1</voice>\r
+ <type>whole</type>\r
</note>\r
<barline location="right">\r
<bar-style>light-heavy</bar-style>\r
(c) 2002--2007 Juergen Reuter <reuter@ipd.uka.de>
*/
+#include "international.hh"
+
#include "ligature-engraver.hh"
#include "note-column.hh"
#include "tuplet-bracket.hh"
#include "translator.icc"
-/*
- * This engraver marks ligatures of any kind by just printing a
- * horizontal square bracket on top of each ligature. See class
- * Ligature_engraver for more information on the interaction between
- * this class and its superclass.
- */
-class Ligature_bracket_engraver : public Ligature_engraver
+class Ligature_bracket_engraver : public Engraver
{
protected:
- virtual Spanner *create_ligature_spanner ();
- virtual void typeset_ligature (Spanner *ligature,
- vector<Grob_info> primitives);
+ virtual void process_music ();
+ virtual void stop_translation_timestep ();
DECLARE_ACKNOWLEDGER (rest);
DECLARE_ACKNOWLEDGER (note_column);
DECLARE_TRANSLATOR_LISTENER (ligature);
public:
TRANSLATOR_DECLARATIONS (Ligature_bracket_engraver);
+
+private:
+ Drul_array<Stream_event *> events_drul_;
+ Spanner *finished_ligature_;
+ Spanner *ligature_;
+ Stream_event *previous_start_event_;
};
IMPLEMENT_TRANSLATOR_LISTENER (Ligature_bracket_engraver, ligature);
void
Ligature_bracket_engraver::listen_ligature (Stream_event *ev)
{
- Ligature_engraver::listen_ligature (ev);
+ Direction d = to_dir (ev->get_property ("span-direction"));
+ ASSIGN_EVENT_ONCE (events_drul_[d], ev);
}
Ligature_bracket_engraver::Ligature_bracket_engraver ()
{
-}
-
-Spanner *
-Ligature_bracket_engraver::create_ligature_spanner ()
-{
- return make_spanner ("LigatureBracket", SCM_EOL);
+ ligature_ = 0;
+ finished_ligature_ = 0;
+ events_drul_[LEFT] = events_drul_[RIGHT] = 0;
+ previous_start_event_ = 0;
}
void
-Ligature_bracket_engraver::typeset_ligature (Spanner *, vector<Grob_info>)
+Ligature_bracket_engraver::process_music()
{
- // no real ligature to typeset; the LigatureBracket just does it
+ if (events_drul_[STOP])
+ {
+ if (!ligature_)
+ {
+ events_drul_[STOP]->origin ()->warning (_ ("cannot find start of ligature"));
+ return;
+ }
+
+ finished_ligature_ = ligature_;
+ ligature_ = 0;
+ previous_start_event_ = 0;
+ }
+
+ if (events_drul_[START])
+ {
+ if (ligature_)
+ {
+ events_drul_[START]->origin ()->warning (_ ("already have a ligature"));
+ return;
+ }
+
+ previous_start_event_ = events_drul_[START];
+ ligature_ = make_spanner ("LigatureBracket", events_drul_[START]->self_scm ());
+ }
}
void
Ligature_bracket_engraver::acknowledge_note_column (Grob_info info)
{
- if (current_ligature ())
+ if (ligature_)
{
- Tuplet_bracket::add_column (current_ligature (),
- dynamic_cast<Item *> (info.grob ()));
-
- // avoid "junking empty ligature" message by acknowledging dummy
- // note head
- Ligature_engraver::acknowledge_note_head (Grob_info ());
+ Tuplet_bracket::add_column (ligature_,
+ info.item ());
+ add_bound_item (ligature_, info.item());
}
}
void
Ligature_bracket_engraver::acknowledge_rest (Grob_info info)
{
- if (current_ligature ())
- Ligature_engraver::acknowledge_rest (info);
+ acknowledge_note_column(info);
+}
+
+
+void
+Ligature_bracket_engraver::stop_translation_timestep ()
+{
+ events_drul_[LEFT] =
+ events_drul_[RIGHT] = 0;
+ finished_ligature_ = 0;
}
ADD_ACKNOWLEDGER (Ligature_bracket_engraver, rest);
ADD_TRANSLATOR (Ligature_bracket_engraver,
/* doc */ "Handles Ligature_events by engraving Ligature brackets.",
- /* create */ "TupletBracket",
+ /* create */ "LigatureBracket",
/* read */ "",
/* write */ "");
LILYPOND_JOBS=$(if $(CPU_COUNT),-djob-count=$(CPU_COUNT),)
LILYPOND_BOOK_LILYPOND_FLAGS=-dbackend=eps --formats=ps,png,pdf $(LILYPOND_JOBS) -dinclude-eps-fonts -dgs-load-fonts --header=texidoc -I $(top-src-dir)/input/manual -dcheck-internal-types -ddump-signatures -danti-alias-factor=$(ANTI_ALIAS_FACTOR)
LILYPOND_BOOK_VERBOSE = --verbose
-LILYPOND_BOOK_FLAGS = --process="$(LILYPOND_BINARY) $(LILYPOND_BOOK_LILYPOND_FLAGS)" $(LILYPOND_BOOK_VERBOSE)
+LILYPOND_BOOK_INFO_IMAGES_DIR = $(if $(INFO_IMAGES_DIR),--info-images-dir=$(INFO_IMAGES_DIR),)
+LILYPOND_BOOK_FLAGS = --process="$(LILYPOND_BINARY) $(LILYPOND_BOOK_LILYPOND_FLAGS)" $(LILYPOND_BOOK_VERBOSE) $(LILYPOND_BOOK_INFO_IMAGES_DIR)
TEXINPUTS=$(top-src-dir)/tex/::
export TEXINPUTS
pass
conversions = []
-error_file = sys.stderr
+stderr_write = lilylib.stderr_write
+
+def warning (str):
+ stderr_write (_ ("warning: %s") % str)
def conv(str):
if re.search ('\\\\multi', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "\\multi")
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "\\multi")
+ stderr_write ('\n')
return str
-conversions.append (((0,1,9), conv, '\\header { key = concat + with + operator }'))
+conversions.append (((0,1,9), conv, _ ('\\header { key = concat + with + operator }')))
def conv (str):
if re.search ('\\\\octave', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "\\octave")
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "\\octave")
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
# raise FatalConversionError ()
return str
conversions.append ((
- ((0,1,19), conv, 'deprecated \\octave; cannot convert automatically')))
+ ((0,1,19), conv, _ ('deprecated %s') % '\\octave')))
return str
conversions.append ((
- ((0,1,20), conv, 'deprecated \\textstyle, new \\key syntax')))
+ ((0,1,20), conv, _ ('deprecated \\textstyle, new \\key syntax'))))
return str
conversions.append ((
- ((1,0,0), conv, '0.1.21 -> 1.0.0 ')))
+ ((1,0,0), conv, _ ("bump version for release"))))
def conv(str):
if re.search ('\\\\header', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("new \\header format"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("new \\header format"))
+ stderr_write ('\n')
return str
-conversions.append (((1,0,2), conv, '\\header { key = concat + with + operator }'))
+conversions.append (((1,0,2), conv, _ ('\\header { key = concat + with + operator }')))
def conv(str):
def conv(str):
if re.search ('[a-zA-Z]+ = *\\translator',str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("\\translator syntax"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("\\translator syntax"))
+ stderr_write ('\n')
# raise FatalConversionError ()
return str
def conv(str):
if re.search ('\\\\repeat',str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "\\repeat")
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "\\repeat")
+ stderr_write ('\n')
# raise FatalConversionError ()
return str
conversions.append (((1,0,18), conv,
- '\\repeat NUM Music Alternative -> \\repeat FOLDSTR Music Alternative'))
+ _ ('\\repeat NUM Music Alternative -> \\repeat FOLDSTR Music Alternative')))
def conv(str):
return str
conversions.append (((1,1,52), conv,
- 'deprecate \\grouping'))
+ _ ('deprecate %s') % '\\grouping'))
def conv(str):
if re.search ('\\\\repetitions',str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "\\repetitions")
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "\\repetitions")
+ stderr_write ('\n')
# raise FatalConversionError ()
return str
conversions.append (((1,3,23), conv,
- '\\\\repetitions feature dropped'))
+ _ ('deprecate %s ') % '\\repetitions'))
str = re.sub ("\\\\musicalpitch *{([0-9 -]+)}",
"\\\\musicalpitch #'(\\1)", str)
if re.search ('\\\\notenames',str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("new \\notenames format"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("new \\notenames format"))
+ stderr_write ('\n')
return str
conversions.append (((1,3,38), conv, '\musicalpitch { a b c } -> #\'(a b c)'))
def conv (str):
if re.search ('\\[:',str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("new tremolo format"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("new tremolo format"))
+ stderr_write ('\n')
return str
conversions.append (((1,3,41), conv,
return str
conversions.append (((1,3,42), conv,
- 'Staff_margin_engraver deprecated, use Instrument_name_engraver'))
+ _ ('Staff_margin_engraver deprecated, use Instrument_name_engraver')))
def conv (str):
def conv (str):
if re.search ('\\\\keysignature', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("new tremolo format"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % '\\keysignature')
+ stderr_write ('\n')
return str
return str
conversions.append (((1,3,93), conv,
- 'property definiton case (eg. onevoice -> oneVoice)'))
+ _ ('change property definiton case (eg. onevoice -> oneVoice)')))
def conv (str):
str = re.sub ('ChordNames*', 'ChordNames', str)
if re.search ('\\\\textscript "[^"]* *"[^"]*"', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("new \\textscript markup text"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("new \\textscript markup text"))
+ stderr_write ('\n')
str = re.sub ('\\textscript +("[^"]*")', '\\textscript #\\1', str)
str = re.sub ('\n([^ \t\n]+)[ \t]*= *', regularize_assignment, str)
return str
-conversions.append (((1,3,117), conv, 'identifier names: $!foo_bar_123 -> xfooBarABC'))
+conversions.append (((1,3,117), conv, _ ('identifier names: %s') % '$!foo_bar_123 -> xfooBarABC'))
str = re.sub ('point-and-click +#t', 'point-and-click line-column-location', str)
return str
-conversions.append (((1,3,138), conv, 'point-and-click argument changed to procedure.'))
+conversions.append (((1,3,138), conv, _ ('point-and-click argument changed to procedure.')))
def conv (str):
str = re.sub ("([^ \t;#]);", "\\1", str)
return str
-conversions.append (((1,3,146), conv, 'semicolons removed'))
+conversions.append (((1,3,146), conv, _('semicolons removed')))
def conv (str):
return str
# 40 ?
-conversions.append (((1,5,40), conv, 'breakAlignOrder property names'))
+conversions.append (((1,5,40), conv, _ ('%s property names') % 'breakAlignOrder'))
str = re.sub ('textNonEmpty *= *##f', "TextScript \\set #'no-spacing-rods = ##t", str)
return str
-conversions.append (((1,5,58), conv, 'deprecate textNonEmpty'))
+conversions.append (((1,5,58), conv, _ ('deprecate %s') % 'textNonEmpty'))
def conv (str):
if re.search (r'\addlyrics',str) \
and re.search ('automaticMelismata', str) == None:
- error_file.write ('\n')
- error_file.write (NOT_SMART % "automaticMelismata; turned on by default since 1.5.67.")
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "automaticMelismata; turned on by default since 1.5.67.")
+ stderr_write ('\n')
raise FatalConversionError ()
return str
conversions.append (((1,5,67), conv,
- 'automaticMelismata turned on by default'))
+ _ ('automaticMelismata turned on by default')))
def conv (str):
def conv(str):
if re.search( r'\\GraceContext', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "GraceContext")
- error_file.write (FROM_TO \
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "GraceContext")
+ stderr_write (FROM_TO \
% ("GraceContext", "#(add-to-grace-init .. )"))
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
str = re.sub ('HaraKiriStaffContext', 'RemoveEmptyStaffContext', str)
return str
-conversions.append (((1,7,19), conv,"remove GraceContext"))
+conversions.append (((1,7,19), conv, _ ("remove %s") % "GraceContext"))
def conv(str):
if re.search( r'-(start|stop)Cluster', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("cluster syntax"))
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("cluster syntax"))
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
return str
-conversions.append (((1,7,24), conv,"cluster syntax"))
+conversions.append (((1,7,24), conv, _ ("cluster syntax")))
def conv(str):
str = re.sub (r"\\property *Staff\.(Sustain|Sostenuto|UnaCorda)Pedal *\\revert *#'pedal-type", '', str)
return str
-conversions.append (((1,7,28), conv,"new Pedal style syntax"))
+conversions.append (((1,7,28), conv, _ ("new Pedal style syntax")))
return str
-conversions.append (((1,9,0), conv, """New relative mode,
-Postfix articulations, new text markup syntax, new chord syntax."""))
+conversions.append (((1,9,0), conv, _ ("""New relative mode,
+Postfix articulations, new text markup syntax, new chord syntax.""")))
def conv (str):
if re.search ("font-style",str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "font-style")
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "font-style")
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
str = re.sub (r'@\\markup', r'-\\markup', str)
return str
-conversions.append (((1,9,1), conv, """Remove - before articulation"""))
+conversions.append (((1,9,1), conv, _ ("""Remove - before articulation""")))
def conv (str):
str = re.sub ('ly:set-context-property',
'acciaccatura', str)
if re.search ("context-spec-music", str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "context-spec-music")
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "context-spec-music")
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
return str
conversions.append (((1,9,3), conv,
- """\\acciaccatura misspelling, fingerHorizontalDirection -> fingeringOrientations"""))
+ (_ ("%s misspelling") % "\\acciaccatura") + \
+ ", fingerHorizontalDirection -> fingeringOrientations"))
def conv (str):
if re.search ('\\figures', str):
- error_file.write ("Warning: attempting automatic \\figures conversion. Check results!");
+ warning (_ ("attempting automatic \\figures conversion. Check results!"));
def figures_replace (m):
return str
-conversions.append (((1,9,4), conv, 'Swap < > and << >>'))
+conversions.append (((1,9,4), conv, _ ('Swap < > and << >>')))
def conv (str):
def conv (str):
if re.search ("ly:get-font", str) :
- error_file.write ('\n')
- error_file.write (NOT_SMART % "(ly:-get-font")
- error_file.write ('\n')
- error_file.write (FROM_TO \
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "(ly:-get-font")
+ stderr_write ('\n')
+ stderr_write (FROM_TO \
% ("(ly:paper-get-font (ly:grob-get-paper foo) .. )",
"(ly:paper-get-font (ly:grob-get-paper foo) .. )"))
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
if re.search ("\\pitch *#", str) :
- error_file.write ('\n')
- error_file.write (NOT_SMART % "\\pitch")
- error_file.write ('\n')
- error_file.write ("Use Scheme code to construct arbitrary note events.")
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "\\pitch")
+ stderr_write ('\n')
+ stderr_write (_ ("Use Scheme code to construct arbitrary note events."))
+ stderr_write ('\n')
raise FatalConversionError ()
return str
-conversions.append (((1,9,6), conv, 'ly:get-font deprecated.'))
+conversions.append (((1,9,6), conv, _ ('deprecate %s') % 'ly:get-font'))
def conv (str):
def sub_alteration (m):
m= re.search ("\\\\outputproperty #([^#]+)[\t\n ]*#'([^ ]+)", str)
if m:
- error_file.write (\
+ stderr_write (_ (\
r"""\outputproperty found,
Please hand-edit, using
\applyoutput #(outputproperty-compatibility %s '%s <GROB PROPERTY VALUE>)
-as a substitution text.""" % (m.group (1), m.group (2)) )
+as a substitution text.""") % (m.group (1), m.group (2)) )
raise FatalConversionError ()
if re.search ("ly:(make-pitch|pitch-alteration)", str) \
or re.search ("keySignature", str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "pitches")
- error_file.write ('\n')
- error_file.write (
- """The alteration field of Scheme pitches was multiplied by 2
-to support quarter tone accidentals. You must update the following constructs by manually:
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "pitches")
+ stderr_write ('\n')
+ stderr_write (
+ _ ("""The alteration field of Scheme pitches was multiplied by 2
+to support quarter tone accidentals. You must update the following constructs manually:
* calls of ly:make-pitch and ly:pitch-alteration
* keySignature settings made with \property
-""")
+"""))
raise FatalConversionError ()
return str
conversions.append (((1,9,7), conv,
- '''use symbolic constants for alterations,
-remove \\outputproperty, move ly:verbose into ly:get-option'''))
+ _ ('''use symbolic constants for alterations,
+remove \\outputproperty, move ly:verbose into ly:get-option''')))
def conv (str):
if re.search ("dash-length",str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "dash-length")
- error_file.write ('\n')
- error_file.write (FROM_TO % ("dash-length", "dash-fraction"))
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "dash-length")
+ stderr_write ('\n')
+ stderr_write (FROM_TO % ("dash-length", "dash-fraction"))
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
return str
str = re.sub (r"\\property ([a-zA-Z]+)\s*\.\s*automaticMelismata\s*=\s*##([ft])", func, str)
return str
-conversions.append (((2,1,4), conv, """removal of automaticMelismata; use melismaBusyProperties instead."""))
+conversions.append (((2,1,4), conv, _ ("""removal of automaticMelismata; use melismaBusyProperties instead.""")))
def conv (str):
if re.search (r'\\partcombine', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "\\partcombine")
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "\\partcombine")
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
# this rule doesn't really work,
return str
-conversions.append (((2,1,17), conv, """\\partcombine syntax change to \\newpartcombine"""))
+conversions.append (((2,1,17), conv, _ ("\\partcombine syntax change to \\newpartcombine")))
def conv (str):
def conv (str):
if re.search ('include "drumpitch', str):
- error_file.write ("Drums found. Enclose drum notes in \\drummode")
+ stderr_write (_ ("Drums found. Enclose drum notes in \\drummode"))
str = re.sub (r'\\include "drumpitch-init.ly"','', str)
if re.search ('drums->paper', str):
- error_file.write ("\nDrum notation found. Check file manually!")
+ stderr_write (_ ("\n%s found. Check file manually!\n") % _("Drum notation"))
str = re.sub (r"""\\apply\s+#\(drums->paper\s+'([a-z]+)\)""",
r"""\property DrumStaff.drumStyleTable = #\1-style""",
str)
if re.search ('Thread', str):
- error_file.write ("\nThread found. Check file manually!\n");
+ stderr_write (_ ("\n%s found. Check file manually!\n") % "Thread");
str = re.sub (r"""(\\once\s*)?\\property\s+Thread\s*\.\s*NoteHead\s*"""
+ r"""\\(set|override)\s*#'style\s*=\s*#'harmonic"""
str = re.sub (r"""Thread""", """Voice""", str)
if re.search ('\bLyrics\b', str):
- error_file.write ("\nLyrics found. Check file manually!\n");
+ stderr_write (_ ("\n%s found. Check file manually!\n") % "Lyrics");
str = re.sub (r"""LyricsVoice""", r"""L@ricsVoice""", str)
str = re.sub (r"""\bLyrics\b""", r"""LyricsVoice""", str)
return str
-conversions.append (((2,1,19), conv, """Drum notation changes, Removing \\chordmodifiers, \\notenames.
-Harmonic notes. Thread context removed. Lyrics context removed."""))
+conversions.append (((2,1,19), conv, _ ("""Drum notation changes, Removing \\chordmodifiers, \\notenames.
+Harmonic notes. Thread context removed. Lyrics context removed.""")))
def conv (str):
str = re.sub (r'nonevent-skip', 'skip-music', str)
brew-new-markup-molecule -> Text_item::print
LyricsVoice -> Lyrics
tupletInvisible -> TupletBracket \set #'transparent
-Grob::preset_extent removed.
-""" ))
+%s.
+""" % (_ ("remove %s") % "Grob::preset_extent")))
def conv (str):
str = re.sub ('Molecule', 'Stencil', str)
return str
-conversions.append (((2,1,22), conv, """new syntax for property settings:
+conversions.append (((2,1,22), conv, """%s
\\set A.B = #C , \\unset A.B
\\override A.B #C = #D, \\revert A.B #C
-"""))
+""" % _ ("new syntax for property settings:")))
def conv (str):
def subst_in_trans (match):
return str
-conversions.append (((2,1,23), conv, """Property setting syntax in \\translator{ }"""))
+conversions.append (((2,1,23), conv, _ ("Property setting syntax in \\translator{ }")))
+
def conv (str):
str = re.sub (r'music-list\?', 'ly:music-list?', str)
str = re.sub (r'\|\s*~', '~ |', str)
str = re.sub (r'ly:get-broken-into', 'ly:spanner-broken-into', str)
str = re.sub (r'Melisma_engraver', 'Melisma_translator', str)
if re.search ("ly:get-paper-variable", str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "ly:paper-get-variable")
- error_file.write ('\n')
- error_file.write ('use (ly:paper-lookup (ly:grob-paper ))')
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "ly:paper-get-variable")
+ stderr_write ('\n')
+ stderr_write (_ ('use %s') % '(ly:paper-lookup (ly:grob-paper ))')
+ stderr_write ('\n')
raise FatalConversionError ()
str = re.sub (r'\\defaultAccidentals', "#(set-accidental-style 'default)", str)
return str
-conversions.append (((2,1,25), conv, """Scheme grob function renaming"""))
+conversions.append (((2,1,25), conv, _ ("Scheme grob function renaming")))
def conv (str):
return str
-conversions.append (((2,1,26), conv, """More Scheme function renaming"""))
+conversions.append (((2,1,26), conv, _ ("More Scheme function renaming")))
def conv (str):
def subst (m):
- g = string.atoi (m.group (2))
+ g = int (m.group (2))
o = g / 12
g -= o * 12
if g < 0:
return str
conversions.append (((2, 2, 0), conv,
- '''clean up version. '''))
+ _ ("bump version for release")))
def conv (str):
return re.sub (r'\\apply\b', r'\\applymusic', str)
def conv (str):
if re.search ('textheight', str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "textheight")
- error_file.write ('\n')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
- error_file.write (
-"""Page layout has been changed, using paper size and margins.
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "textheight")
+ stderr_write ('\n')
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
+ stderr_write (
+_ ("""Page layout has been changed, using paper size and margins.
textheight is no longer used.
-""")
+"""))
str = re.sub (r'\\OrchestralScoreContext', '\\Score', str)
def func(m):
if m.group(1) not in ['RemoveEmptyStaff',
return str
conversions.append (((2, 3, 4), conv,
- '''remove \\notes'''))
+ _ ('remove %s') % '\\notes'))
str = re.sub (r'\\addlyrics', r'\\oldaddlyrics', str)
str = re.sub (r'\\newlyrics', r'\\addlyrics', str)
if re.search (r"\\override\s*TextSpanner", str):
- error_file.write ("\nWarning: TextSpanner has been split into DynamicTextSpanner and TextSpanner\n")
+ stderr_write ("\nWarning: TextSpanner has been split into DynamicTextSpanner and TextSpanner\n")
return str
conversions.append (((2, 3, 10), conv,
return str
conversions.append (((2, 3, 16), conv,
- '''\\foo -> \\foomode (for chords, notes, etc.)
-fold \\new FooContext \\foomode into \\foo.'''))
+ _ ('''\\foo -> \\foomode (for chords, notes, etc.)
+fold \\new FooContext \\foomode into \\foo.''')))
def conv (str):
str = re.sub (r'(slur|stem|phrasingSlur|tie|dynamic|dots|tuplet|arpeggio|)Both', r'\1Neutral', str)
return str
conversions.append (((2, 3, 17), conv,
- '''\\foo -> \\foomode (for chords, notes, etc.)
-fold \\new FooContext \\foomode into \\foo.'''))
+ '''slurBoth -> slurNeutral, stemBoth -> stemNeutral, etc.
+\\applymusic #(remove-tag 'foo) -> \\removeWithTag 'foo'''))
def conv (str):
str = re.sub (r'\\paper', r'\\layout', str)
str = re.sub (r'\\bookpaper', r'\\paper', str)
if re.search ('paper-set-staff-size', str):
- error_file.write ('''\nWarning: staff size should be changed at top-level
+ warning (_ ('''staff size should be changed at top-level
with
#(set-global-staff-size <STAFF-HEIGHT-IN-POINT>)
-''')
+'''))
str = re.sub (r'#\(paper-set-staff-size', '%Use set-global-staff-size at toplevel\n% #(layout-set-staff-size', str)
conversions.append (((2, 3, 22),
conv,
- '''paper -> layout
- bookpaper -> paper''' ))
+ '''paper -> layout, bookpaper -> paper''' ))
def conv (str):
conversions.append (((2, 3, 24),
conv,
- '''regularize other identifiers.'''))
+ _ ('''regularize other identifiers''')))
def conv (str):
str = re.sub ('petrucci_c1', 'petrucci-c1', str)
conversions.append (((2, 4, 0),
conv,
- ''))
+ _ ("bump version for release")))
def conv (str):
str = re.sub (r'\\quote\s+"?([a-zA-Z0-9]+)"?\s+([0-9.*/]+)',
r'\\quoteDuring #"\1" { \skip \2 }',
- str
- )
+ str)
return str
conversions.append (((2, 5, 0),
conv,
- ''))
+ '\\quote -> \\quoteDuring'))
def conv (str):
if encoding == 'latin1':
return match.group (2)
- error_file.write ('\n')
- error_file.write (NOT_SMART % ("\\encoding: %s" % encoding))
- error_file.write ('\n')
- error_file.write (_ ("LilyPond source must be UTF-8"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % ("\\encoding: %s" % encoding))
+ stderr_write ('\n')
+ stderr_write (_ ("LilyPond source must be UTF-8"))
+ stderr_write ('\n')
if encoding == 'TeX':
- error_file.write (_ ("Try the texstrings backend"))
- error_file.write ('\n')
+ stderr_write (_ ("Try the texstrings backend"))
+ stderr_write ('\n')
else:
- error_file.write ( _("Do something like: %s") % \
+ stderr_write ( _("Do something like: %s") % \
("recode %s..utf-8 FILE" % encoding))
- error_file.write ('\n')
- error_file.write (_ ("Or save as UTF-8 in your editor"))
- error_file.write ('\n')
+ stderr_write ('\n')
+ stderr_write (_ ("Or save as UTF-8 in your editor"))
+ stderr_write ('\n')
raise FatalConversionError ()
return match.group (0)
conversions.append (((2, 5, 13),
conv,
- '\\encoding: smart recode latin1..utf-8. Remove ly:point-and-click'))
+ _ ('\\encoding: smart recode latin1..utf-8. Remove ly:point-and-click')))
def conv (str):
if re.search ("ly:stencil-set-extent!", str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "ly:stencil-set-extent!")
- error_file.write ('\n')
- error_file.write ('use (set! VAR (ly:make-stencil (ly:stencil-expr VAR) X-EXT Y-EXT))\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "ly:stencil-set-extent!")
+ stderr_write ('\n')
+ stderr_write ('use (set! VAR (ly:make-stencil (ly:stencil-expr VAR) X-EXT Y-EXT))\n')
raise FatalConversionError ()
if re.search ("ly:stencil-align-to!", str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % "ly:stencil-align-to!")
- error_file.write ('\n')
- error_file.write ('use (set! VAR (ly:stencil-aligned-to VAR AXIS DIR))\n')
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % "ly:stencil-align-to!")
+ stderr_write ('\n')
+ stderr_write ('use (set! VAR (ly:stencil-aligned-to VAR AXIS DIR))\n')
raise FatalConversionError ()
return str
conversions.append (((2, 5, 17),
conv,
- 'ly:stencil-set-extent! removed'))
+ _ ('remove %s') % 'ly:stencil-set-extent!'))
def conv (str):
str = re.sub (r"ly:warn\b", 'ly:warning', str)
def conv (str):
if re.search ("(override-|revert-)auto-beam-setting", str)\
or re.search ("autoBeamSettings", str):
- error_file.write ('\n')
- error_file.write (NOT_SMART % _ ("auto beam settings"))
- error_file.write ('\n')
- error_file.write ('''
+ stderr_write ('\n')
+ stderr_write (NOT_SMART % _ ("auto beam settings"))
+ stderr_write ('\n')
+ stderr_write (_ ('''
Auto beam settings must now specify each interesting moment in a measure
explicitely; 1/4 is no longer multiplied to cover moments 1/2 and 3/4 too.
-''')
- error_file.write (UPDATE_MANUALLY)
- error_file.write ('\n')
+'''))
+ stderr_write (UPDATE_MANUALLY)
+ stderr_write ('\n')
raise FatalConversionError ()
return str
conversions.append (((2, 5, 21),
conv,
- 'warn about auto beam settings'))
+ _ ('warn about auto beam settings')))
def conv (str):
str = re.sub (r"unfoldrepeats", 'unfoldRepeats', str)
return str
conversions.append (((2, 5, 25), conv,
-
- 'unfoldrepeats -> unfoldRepeats,'
- + 'compressmusic -> compressMusic'))
+ 'unfoldrepeats -> unfoldRepeats, compressmusic -> compressMusic'))
def conv (str):
return str
conversions.append (((2, 6, 0), conv,
-
- 'dummy rule for 2.6'))
+ _ ("bump version for release")))
return str
conversions.append (((2, 7, 4), conv,
- '''keyAccidentalOrder->keyAlterationOrder'''))
+ '''keyAccidentalOrder -> keyAlterationOrder'''))
return str
conversions.append (((2, 7, 6), conv,
- '''Performer_group_performer -> Performer_group, Engraver_group_engraver -> Engraver_group
+ '''Performer_group_performer -> Performer_group, Engraver_group_engraver -> Engraver_group,
inside-slur -> avoid-slur'''))
subber, str)
if re.search ('bar-size-procedure', str):
- error_file.write (NOT_SMART % "bar-size-procedure")
+ stderr_write (NOT_SMART % "bar-size-procedure")
if re.search ('space-function', str):
- error_file.write (NOT_SMART % "space-function")
+ stderr_write (NOT_SMART % "space-function")
if re.search ('verticalAlignmentChildCallback', str):
- error_file.write ('verticalAlignmentChildCallback has been deprecated')
+ stderr_write (_ ('verticalAlignmentChildCallback has been deprecated'))
return str
conversions.append (((2, 7, 13), conv,
- '''layout engine refactoring. [FIXME] '''))
+ '''layout engine refactoring [FIXME]'''))
return str
conversions.append (((2, 7, 14), conv,
- '''Remove callbacks property, deprecate XY-extent-callback. '''))
+ _ ('Remove callbacks property, deprecate XY-extent-callback.')))
def conv (str):
if re.search ('[XY]-offset-callbacks', str):
- error_file.write (NOT_SMART % "[XY]-offset-callbacks")
+ stderr_write (NOT_SMART % "[XY]-offset-callbacks")
if re.search ('position-callbacks', str):
- error_file.write (NOT_SMART % "position-callbacks")
+ stderr_write (NOT_SMART % "position-callbacks")
return str
conversions.append (((2, 7, 15), conv,
- '''Use grob closures iso. XY-offset-callbacks.'''))
+ _ ('Use grob closures iso. XY-offset-callbacks.')))
def conv (str):
return str
conversions.append (((2, 7, 24), conv,
- """deprecate number-visibility"""))
+ _ ('deprecate %s') % 'number-visibility'))
def conv (str):
str = re.sub (r"ly:spanner-get-bound", "ly:spanner-bound", str)
return str
conversions.append (((2, 7, 32), conv,
- """foobar -> foo-bar for \paper, \layout"""))
+ _ ("foobar -> foo-bar for \paper, \layout")))
def conv (str):
str = re.sub ('debug-beam-quanting', 'debug-beam-scoring', str)
r"""\\override \g<context>TupletNumber #'text = #tuplet-number::calc-fraction-text""", str)
if re.search ('tupletNumberFormatFunction', str):
- error_file.write ("\n")
- error_file.write ("tupletNumberFormatFunction has been removed. Use #'text property on TupletNumber")
- error_file.write ("\n")
+ stderr_write ("\n")
+ stderr_write ("tupletNumberFormatFunction has been removed. Use #'text property on TupletNumber")
+ stderr_write ("\n")
return str
str = re.sub (r'\\midi\s*{\s*\\tempo ([0-9]+)\s*([.]*)\s*=\s*([0-9]+)\s*}', sub_tempo, str)
return str
-conversions.append (((2, 9, 16), conv, """deprecate \\tempo in \\midi"""))
+conversions.append (((2, 9, 16), conv, _ ("deprecate \\tempo in \\midi")))
def conv (str):
str = re.sub ('printfirst-page-number', 'print-first-page-number', str)
def conv (str):
return str
-conversions.append (((2, 10, 0), conv, """bump version for release"""))
+conversions.append (((2, 10, 0), conv, _ ("bump version for release")))
def conv (str):
return str
-conversions.append (((2, 11, 5), conv, """deprecate cautionary-style. Use AccidentalCautionary properties"""))
+conversions.append (((2, 11, 5), conv, _ ("deprecate cautionary-style. Use AccidentalCautionary properties")))
'standard-alteration-glyph-name-alist')
return str
-conversions.append (((2, 11, 6), conv, """Rename accidental glyphs, use glyph-name-alist."""))
+conversions.append (((2, 11, 6), conv, _ ("Rename accidental glyphs, use glyph-name-alist.")))
def conv (str):
r"\override Beam #'breakable", str)
str = re.sub (r'addquote' , 'addQuote', str)
if re.search ("Span_dynamic_performer", str):
- error_file.write ("Span_dynamic_performer has been merged into Dynamic_performer")
+ stderr_write ("Span_dynamic_performer has been merged into Dynamic_performer")
return str
conversions.append (((2, 11, 10), conv, """allowBeamBreak -> Beam #'breakable = ##t
addquote -> addQuote
-
"""))
def conv (str):
str)
if re.search ('edge-text', str):
- error_file.write (NOT_SMART % _ ("edge-text settings for TextSpanner."))
- error_file.write (_ ("Use\n\n%s") %
+ stderr_write (NOT_SMART % _ ("edge-text settings for TextSpanner."))
+ stderr_write (_ ("Use\n\n%s") %
"\t\\override TextSpanner #'bound-details #'right #'text = <right-text>\n"
"\t\\override TextSpanner #'bound-details #'left #'text = <left-text>\n")
r"scripts.caesura.curved", str)
if re.search ('dash-fraction', str):
- error_file.write (NOT_SMART % _ ("all settings related to dashed lines.\n"))
- error_file.write (_ ("Use \\override ... #'style = #'line for solid lines and\n"))
- error_file.write (_ ("\t\\override ... #'style = #'dashed-line for dashed lines."))
+ stderr_write (NOT_SMART % _ ("all settings related to dashed lines.\n"))
+ stderr_write (_ ("Use \\override ... #'style = #'line for solid lines and\n"))
+ stderr_write (_ ("\t\\override ... #'style = #'dashed-line for dashed lines."))
return str
-conversions.append (((2, 11, 35), conv, """scripts.caesura -> scripts.caesura.curved. Use #'style not #'dash-fraction to select solid/dashed lines."""))
+conversions.append (((2, 11, 35), conv, """scripts.caesura -> scripts.caesura.curved.
+""" + _ ("Use #'style not #'dash-fraction to select solid/dashed lines.")))
def conv (str):
str = re.sub (r"setEasyHeads", r"easyHeadsOn", str)
self.music = SequentialMusic ()
self.music.elements = music
else:
- sys.stderr.write ("WARNING: Unable to set the music %s for the repeat %s" % (music, self))
+ sys.stderr.write (_ ("WARNING: Unable to set the music %s for the repeat %s" % (music, self)))
def add_ending (self, music):
self.endings.append (music)
def print_ly (self, printer):
if self.music:
self.music.print_ly (printer)
else:
- sys.stderr.write ("WARNING: Encountered repeat without body\n")
+ sys.stderr.write (_ ("WARNING: Encountered repeat without body\n"))
printer.dump ('{}')
if self.endings:
printer.dump ('\\alternative {')
class PedalEvent (SpanEvent):
def ly_expression (self):
return {-1: '\\sustainDown',
+ 0:'\\sustainUp\\sustainDown',
1:'\\sustainUp'}.get (self.span_direction, '')
+class TextSpannerEvent (SpanEvent):
+ def ly_expression (self):
+ return {-1: '\\startTextSpan',
+ 1:'\\stopTextSpan'}.get (self.span_direction, '')
+
+class BracketSpannerEvent (SpanEvent):
+ def ly_expression (self):
+ return {-1: '\\startGroup',
+ 1:'\\stopGroup'}.get (self.span_direction, '')
+
+
# type==-1 means octave up, type==-2 means octave down
class OctaveShiftEvent (SpanEvent):
def wait_for_note (self):
- return False;
+ return False
def set_span_type (self, type):
self.span_type = {'up': 1, 'down': -1}.get (type, 0)
def ly_octave_shift_indicator (self):
Event.__init__ (self)
self.direction = 0
def wait_for_note (self):
- return True;
+ return True
def ly_expression (self):
# TODO: Use self.direction for up/down arpeggios
return ('\\arpeggio')
class DynamicsEvent (Event):
def __init__ (self):
self.type = None
- self.available_commands = [ "ppppp", "pppp", "ppp", "pp", "p",
- "mp", "mf",
- "f", "ff", "fff", "ffff",
- "fp", "sf", "sff", "sp", "spp", "sfz", "rfz" ];
def wait_for_note (self):
- return True;
+ return True
def ly_expression (self):
- if self.type == None:
- return;
- elif self.type in self.available_commands:
+ if self.type:
return '\%s' % self.type
else:
- return '-\markup{ \dynamic %s }' % self.type
-
- def print_ly (self, printer):
- if self.type == None:
return
- elif self.type in self.available_commands:
+
+ def print_ly (self, printer):
+ if self.type:
printer.dump ("\\%s" % self.type)
+
+class MarkEvent (Event):
+ def __init__ (self, text="\\default"):
+ self.mark = text
+ def wait_for_note (self):
+ return False
+ def ly_contents (self):
+ if self.mark:
+ return '%s' % self.mark
else:
- printer.dump ("-\\markup{ \\dynamic %s }" % self.type)
+ return "\"ERROR\""
+ def ly_expression (self):
+ return '\\mark %s' % self.ly_contents ()
+
+class MusicGlyphMarkEvent (MarkEvent):
+ def ly_contents (self):
+ if self.mark:
+ return '\\markup { \\musicglyph #"scripts.%s" }' % self.mark
+ else:
+ return ''
class TextEvent (Event):
self.type = None
self.force_direction = None
def wait_for_note (self):
- return True;
+ return True
def direction_mod (self):
return { 1: '^', -1: '_', 0: '-' }.get (self.force_direction, '')
else:
return (4, 4)
except KeyError:
- sys.stderr.write ('error: requested time signature, but time sig unknown\n')
+ sys.stderr.write (_ ("error: requested time signature, but time sig is unknown\n"))
return (4, 4)
# returns clef information in the form ("cleftype", position, octave-shift)
# FIXME: is it ok to default to eight note for grace notes?
return 3
else:
- self.message ("Encountered note at %s with %s duration (no <type> element):" % (self.start, self.duration) )
+ self.message (_ ("Encountered note at %s with %s duration (no <type> element):") % (self.start, self.duration) )
return 0
def get_factor (self):
if instrument_name:
return instrument_name
else:
- sys.stderr.write ("Opps, couldn't find instrument for ID=%s\n" % id)
+ sys.stderr.write (_ ("Unable to find find instrument for ID=%s\n") % id)
return "Grand Piano"
class Part_group (Music_xml_node):
class Tuplet (Music_xml_spanner):
pass
+class Bracket (Music_xml_spanner):
+ pass
+
+class Dashes (Music_xml_spanner):
+ pass
+
class Slur (Music_xml_spanner):
def get_type (self):
return self.type
'bar-style': BarStyle,
'beam' : Beam,
'bend' : Bend,
+ 'bracket' : Bracket,
'chord': Chord,
+ 'dashes' : Dashes,
'dot': Dot,
'direction': Direction,
'direction-type': DirType,
action='append', dest='include_path',
default=[os.path.abspath (os.getcwd ())])
+ p.add_option ('--info-images-dir', help=_ ("format Texinfo output so that Info will "
+ "look for images of music in DIR"),
+ metavar=_ ("DIR"),
+ action='store', dest='info_images_dir',
+ default='')
+
p.add_option ('--left-padding',
- metavar=_("PAD"),
+ metavar=_ ("PAD"),
dest="padding_mm",
- help="Pad left side of music to align music inspite of uneven bar numbers. (in mm)",
+ help=_ ("pad left side of music to align music inspite of uneven bar numbers (in mm)"),
type="float",
default=3.0)
p.add_option ('--pdf',
action="store_true",
dest="create_pdf",
- help=_ ("Create PDF files for use with PDFTeX"),
+ help=_ ("create PDF files for use with PDFTeX"),
default=False)
p.add_option ('', '--psfonts', action="store_true", dest="psfonts",
help=_ ('''extract all PostScript fonts into INPUT.psfonts for LaTeX
p.add_option ('-w', '--warranty',
help=_ ("show warranty and copyright"),
action='store_true')
- p.add_option_group ('bugs',
+ p.add_option_group (_ ('Bugs'),
description=(_ ("Report bugs via")
+ ''' http://post.gmane.org/post.php'''
'''?group=gmane.comp.gnu.lilypond.bugs\n'''))
OUTPUTIMAGE: r'''@noindent
@ifinfo
-@image{%(base)s,,,%(alt)s,%(ext)s}
+@image{%(info_image_path)s,,,%(alt)s,%(ext)s}
@end ifinfo
@html
<p>
# Specifying no extension is most robust.
ext = ''
alt = self.option_dict[ALT]
+ info_image_path = os.path.join (global_options.info_images_dir, base)
str += output[TEXINFO][OUTPUTIMAGE] % vars ()
base = self.basename ()
)
)
)
-)
-"""
+)"""
}
def round_to_two_digits (val):
d.duration_log = {1: 0, 2: 1, 4:2, 8:3, 16:4, 32:5, 64:6, 128:7, 256:8, 512:9}.get (rational_len.denominator (), -1)
d.factor = Rational (rational_len.numerator ())
if d.duration_log < 0:
- error_message ("Encountered rational duration with denominator %s, "
- "unable to convert to lilypond duration" %
+ error_message (_ ("Encountered rational duration with denominator %s, "
+ "unable to convert to lilypond duration") %
rational_len.denominator ())
# TODO: Test the above error message
return None
self.direction = 0
self.event = None
def print_ly (self, printer):
- sys.stderr.write ("Encountered unprocessed marker %s\n" % self)
+ ly.stderr_write (_ ("Encountered unprocessed marker %s\n") % self)
pass
def ly_expression (self):
return ""
return retval.values ()
spanner_event_dict = {
- 'slur' : musicexp.SlurEvent,
'beam' : musicexp.BeamEvent,
+ 'dashes' : musicexp.TextSpannerEvent,
+ 'bracket' : musicexp.BracketSpannerEvent,
'glissando' : musicexp.GlissandoEvent,
+ 'octave-shift' : musicexp.OctaveShiftEvent,
'pedal' : musicexp.PedalEvent,
+ 'slur' : musicexp.SlurEvent,
'wavy-line' : musicexp.TrillSpanEvent,
- 'octave-shift' : musicexp.OctaveShiftEvent,
'wedge' : musicexp.HairpinEvent
}
spanner_type_dict = {
'decreschendo': -1,
'diminuendo': -1,
'continue': 0,
+ 'change': 0,
'up': -1,
'down': -1,
'stop': 1,
if func:
ev = func()
else:
- error_message ('unknown span event %s' % mxl_event)
+ error_message (_ ('unknown span event %s') % mxl_event)
type = mxl_event.get_type ()
if span_direction != None:
ev.span_direction = span_direction
else:
- error_message ('unknown span type %s for %s' % (type, name))
+ error_message (_ ('unknown span type %s for %s') % (type, name))
ev.set_span_type (type)
ev.line_type = getattr (mxl_event, 'line-type', 'solid')
return ev
+
def musicxml_dynamics_to_lily_event (dynentry):
- dynamics_available = ( "p", "pp", "ppp", "pppp", "ppppp", "pppppp",
- "f", "ff", "fff", "ffff", "fffff", "ffffff",
- "mp", "mf", "sf", "sfp", "sfpp", "fp",
- "rf", "rfz", "sfz", "sffz", "fz" )
- if not dynentry.get_name() in dynamics_available:
+ dynamics_available = (
+ "ppppp", "pppp", "ppp", "pp", "p", "mp", "mf",
+ "f", "ff", "fff", "ffff", "fp", "sf", "sff", "sp", "spp", "sfz", "rfz" )
+ dynamicsname = dynentry.get_name ()
+ if dynamicsname == "other-dynamics":
+ dynamicsname = dynentry.get_text ()
+ if not dynamicsname or dynamicsname=="#text":
return
+
+ if not dynamicsname in dynamics_available:
+ # Get rid of - in tag names (illegal in ly tags!)
+ dynamicstext = dynamicsname
+ dynamicsname = string.replace (dynamicsname, "-", "")
+ additional_definitions[dynamicsname] = dynamicsname + \
+ " = #(make-dynamic-script \"" + dynamicstext + "\")"
+ needed_additional_definitions.append (dynamicsname)
event = musicexp.DynamicsEvent ()
- event.type = dynentry.get_name ()
+ event.type = dynamicsname
return event
# Convert single-color two-byte strings to numbers 0.0 - 1.0
return event
-direction_spanners = [ 'octave-shift', 'pedal', 'wedge' ]
+# convert accordion-registration to lilypond.
+# Since lilypond does not have any built-in commands, we need to create
+# the markup commands manually and define our own variables.
+# Idea was taken from: http://lsr.dsi.unimi.it/LSR/Item?id=194
+def musicxml_accordion_to_markup (mxl_event):
+ commandname = "accReg"
+ command = ""
+
+ high = mxl_event.get_maybe_exist_named_child ('accordion-high')
+ if high:
+ commandname += "H"
+ command += """\\combine
+ \\raise #2.5 \\musicglyph #\"accordion.accDot\"
+ """
+ middle = mxl_event.get_maybe_exist_named_child ('accordion-middle')
+ if middle:
+ # By default, use one dot (when no or invalid content is given). The
+ # MusicXML spec is quiet about this case...
+ txt = 1
+ try:
+ txt = string.atoi (middle.get_text ())
+ except ValueError:
+ pass
+ if txt == 3:
+ commandname += "MMM"
+ command += """\\combine
+ \\raise #1.5 \\musicglyph #\"accordion.accDot\"
+ \\combine
+ \\raise #1.5 \\translate #(cons 1 0) \\musicglyph #\"accordion.accDot\"
+ \\combine
+ \\raise #1.5 \\translate #(cons -1 0) \\musicglyph #\"accordion.accDot\"
+ """
+ elif txt == 2:
+ commandname += "MM"
+ command += """\\combine
+ \\raise #1.5 \\translate #(cons 0.5 0) \\musicglyph #\"accordion.accDot\"
+ \\combine
+ \\raise #1.5 \\translate #(cons -0.5 0) \\musicglyph #\"accordion.accDot\"
+ """
+ elif not txt <= 0:
+ commandname += "M"
+ command += """\\combine
+ \\raise #1.5 \\musicglyph #\"accordion.accDot\"
+ """
+ low = mxl_event.get_maybe_exist_named_child ('accordion-low')
+ if low:
+ commandname += "L"
+ command += """\\combine
+ \\raise #0.5 \musicglyph #\"accordion.accDot\"
+ """
+
+ command += "\musicglyph #\"accordion.accDiscant\""
+ command = "\\markup { \\normalsize %s }" % command
+ # Define the newly built command \accReg[H][MMM][L]
+ additional_definitions[commandname] = "%s = %s" % (commandname, command)
+ needed_additional_definitions.append (commandname)
+ return "\\%s" % commandname
+
+def musicxml_accordion_to_ly (mxl_event):
+ txt = musicxml_accordion_to_markup (mxl_event)
+ if txt:
+ ev = musicexp.MarkEvent (txt)
+ return ev
+ return
+
+
+def musicxml_rehearsal_to_ly_mark (mxl_event):
+ text = mxl_event.get_text ()
+ if not text:
+ return
+ # default is boxed rehearsal marks!
+ encl = "box"
+ if hasattr (mxl_event, 'enclosure'):
+ encl = {"none": None, "square": "box", "circle": "circle" }.get (mxl_event.enclosure, None)
+ if encl:
+ text = "\\%s { %s }" % (encl, text)
+ ev = musicexp.MarkEvent ("\\markup { %s }" % text)
+ return ev
+
+# translate directions into Events, possible values:
+# -) string (MarkEvent with that command)
+# -) function (function(mxl_event) needs to return a full Event-derived object
+# -) (class, name) (like string, only that a different class than MarkEvent is used)
+directions_dict = {
+ 'accordion-registration' : musicxml_accordion_to_ly,
+ 'coda' : (musicexp.MusicGlyphMarkEvent, "coda"),
+# 'damp' : ???
+# 'damp-all' : ???
+# 'eyeglasses': ??????
+# 'harp-pedals' :
+# 'image' :
+# 'metronome' :
+ 'rehearsal' : musicxml_rehearsal_to_ly_mark,
+# 'scordatura' :
+ 'segno' : (musicexp.MusicGlyphMarkEvent, "segno"),
+ 'words' : musicxml_words_to_lily_event,
+}
+directions_spanners = [ 'octave-shift', 'pedal', 'wedge', 'dashes', 'bracket' ]
def musicxml_direction_to_lily (n):
# TODO: Handle the <staff> element!
res = []
+ # placement applies to all children!
+ dir = None
+ if hasattr (n, 'placement') and options.convert_directions:
+ dir = musicxml_direction_to_indicator (n.placement)
dirtype_children = []
+ # TODO: The direction-type is used for grouping (e.g. dynamics with text),
+ # so we can't simply flatten them out!
for dt in n.get_typed_children (musicxml.DirType):
dirtype_children += dt.get_all_children ()
for entry in dirtype_children:
+ # backets, dashes, octave shifts. pedal marks, hairpins etc. are spanners:
+ if entry.get_name() in directions_spanners:
+ event = musicxml_spanner_to_lily_event (entry)
+ if event:
+ res.append (event)
+ continue
+
+ # now treat all the "simple" ones, that can be translated using the dict
+ ev = None
+ tmp_tp = directions_dict.get (entry.get_name (), None)
+ if isinstance (tmp_tp, str): # string means MarkEvent
+ ev = musicexp.MarkEvent (tmp_tp)
+ elif isinstance (tmp_tp, tuple): # tuple means (EventClass, "text")
+ ev = tmp_tp[0] (tmp_tp[1])
+ elif tmp_tp:
+ ev = tmp_tp (entry)
+ if ev:
+ # TODO: set the correct direction! Unfortunately, \mark in ly does
+ # not seem to support directions!
+ res.append (ev)
+ continue
if entry.get_name () == "dynamics":
for dynentry in entry.get_all_children ():
if ev:
res.append (ev)
- if entry.get_name () == "words":
- ev = musicxml_words_to_lily_event (entry)
- if ev:
- res.append (ev)
-
- # octave shifts. pedal marks, hairpins etc. are spanners:
- if entry.get_name() in direction_spanners:
- event = musicxml_spanner_to_lily_event (entry)
- if event:
- res.append (event)
-
-
return res
def musicxml_frame_to_lily_event (frame):
continue
if not n.__class__.__name__ == 'Note':
- error_message ('not a Note or Attributes? %s' % n)
+ error_message (_ ('unexpected %s; expected %s or %s or %s') % (n, 'Note', 'Attributes', 'Barline'))
continue
rest = n.get_maybe_exist_typed_child (musicxml.Rest)
if s.get_type () in ('start','stop')]
if slurs:
if len (slurs) > 1:
- error_message ('more than 1 slur?')
+ error_message (_ ('cannot have two simultaneous slurs'))
# record the slur status for the next note in the loop
if not grace:
if slurs[0].get_type () == 'start':
if len (modes_found) > 1:
- error_message ('Too many modes found %s' % modes_found.keys ())
+ error_message (_ ('cannot simultaneously have more than one mode: %s') % modes_found.keys ())
if options.relative:
v = musicexp.RelativeMusic ()
part_ly_voices = {}
for n, v in name_voice.items ():
- progress ("Converting to LilyPond expressions...")
+ progress (_ ("Converting to LilyPond expressions..."))
# musicxml_voice_to_lily_voice returns (lily_voice, {nr->lyrics, nr->lyrics})
part_ly_voices[n] = musicxml_voice_to_lily_voice (v)
under certain conditions. Invoke as `%s --warranty' for more
information.""") % 'lilypond'
+ """
-Copyright (c) 2005--2007 by
+Copyright (c) 2005--2008 by
Han-Wen Nienhuys <hanwen@xs4all.nl>,
Jan Nieuwenhuizen <janneke@gnu.org> and
Reinhold Kainhofer <reinhold@kainhofer.com>
p.add_option ('-r', '--relative',
action = "store_true",
dest = "relative",
- help = _ ("Convert pitches in relative mode."))
+ help = _ ("Convert pitches in relative mode. (Default)"))
+
+ p.add_option ('-a', '--absolute',
+ action = "store_false",
+ dest = "relative",
+ help = _ ("Convert pitches in absolute mode."))
p.add_option ('-l', '--language',
+ metavar=_("LANG"),
action = "store",
- help = _ ("Use a different language file, e.g. 'deutsch' for deutsch.ly."))
+ help = _ ("Use a different language file 'LANG.ly' and corresponding pitch names, e.g. 'deutsch' for deutsch.ly."))
- p.add_option ('--no-articulation-directions', '--nd',
+ p.add_option ('--nd', '--no-articulation-directions',
action = "store_false",
default = True,
dest = "convert_directions",
- help = _ ("Do not convert directions (^, _ or -) for articulations."))
+ help = _ ("Do not convert directions (^, _ or -) for articulations, dynamics, etc."))
p.add_option ('-o', '--output',
metavar=_ ("FILE"),
type='string',
dest='output_name',
help=_ ("set output filename to FILE"))
- p.add_option_group ('bugs',
+ p.add_option_group ( _('Bugs'),
description=(_ ("Report bugs via")
+ ''' http://post.gmane.org/post.php'''
'''?group=gmane.comp.gnu.lilypond.bugs\n'''))
printer.newline ()
for a in set(needed_additional_definitions):
printer.print_verbatim (additional_definitions.get (a, ''))
+ printer.newline ()
printer.newline ()
# Read in the tree from the given I/O object (either file or string) and
def read_musicxml (filename, compressed, use_lxml):
raw_string = None
if compressed:
- progress ("Input file %s is compressed, extracting raw MusicXML data" % filename)
+ progress (_ ("Input file %s is compressed, extracting raw MusicXML data") % filename)
z = zipfile.ZipFile (filename, "r")
container_xml = z.read ("META-INF/container.xml")
if not container_xml:
def convert (filename, options):
- progress ("Reading MusicXML from %s ..." % filename)
+ progress (_ ("Reading MusicXML from %s ...") % filename)
tree = read_musicxml (filename, options.compressed, options.use_lxml)
parts = tree.get_typed_children (musicxml.Part)
driver_ly_name = options.output_name + '.ly'
printer = musicexp.Output_printer()
- progress ("Output to `%s'" % defs_ly_name)
+ progress (_ ("Output to `%s'") % defs_ly_name)
printer.set_file (codecs.open (defs_ly_name, 'wb', encoding='utf-8'))
print_ly_preamble (printer, filename)
printer.close ()
- progress ("Output to `%s'" % driver_ly_name)
+ progress (_ ("Output to `%s'") % driver_ly_name)
printer = musicexp.Output_printer()
printer.set_file (codecs.open (driver_ly_name, 'wb', encoding='utf-8'))
print_ly_preamble (printer, filename)
if filename and os.path.exists (filename):
voices = convert (filename, options)
else:
- progress ("Unable to find input file %s" % args[0])
+ progress (_ ("Unable to find input file %s") % args[0])
if __name__ == '__main__':
main()
# ugh . mf2pt1 is extremely broken, it pollutes CWD iso. creating a
# temp dir.
$(outdir)/%.pfb: %.mf $(outdir)/mf2pt1.mem
- TMP=`mktemp -d $(outdir)/pfbtemp.XXXXXXXXX` ; \
- ( cd $$TMP ; \
- ln -s ../mf2pt1.mem . ; \
- MFINPUTS=../..:../:: $(PERL) ../../$(buildscript-dir)/mf2pt1.pl $(MF2PT1_OPTIONS) $< ) ; \
- mv $$TMP/*pfb $(outdir) ; \
- rm -rf $$TMP
+ TMP=`mktemp -d $(outdir)/pfbtemp.XXXXXXXXX` \
+ && ( cd $$TMP \
+ && ln -s ../mf2pt1.mem . \
+ && MFINPUTS=$(top-src-dir)/mf:..:: $(PERL) $(top-src-dir)/buildscripts/mf2pt1.pl $(MF2PT1_OPTIONS) $< ) \
+ && mv $$TMP/*pfb $(outdir); \
+ rm -rf $$TMP
$(outdir)/mf2pt1.mem: mf2pt1.mp
cd $(outdir) && mpost -progname=mpost -ini $(top-src-dir)/mf/mf2pt1.mp \\dump
$(outdir)/%.info: $(outdir)/%.texi
# makeinfo MUST have PNGs in cwd for info images to work
- cd $(outdir) && $(MAKEINFO) -I$(srcdir) --output=$(@F) $(<F)
+ $(MAKEINFO) -I$(outdir) --output=$@ $<
$(outdir)/%-big-page.html: $(outdir)/%.texi
$(MAKEINFO) -I $(outdir) --output=$@ --css-include=$(top-src-dir)/Documentation/texinfo.css --html --no-split -D bigpage --no-headers $<
$(outdir)/%.ps.gz.omf: %.texi
$(call GENERATE_OMF,ps.gz)
-# Generic rule not possible?
-$(outdir)/%/%.html: $(outdir)/%.texi
- $(MAKEINFO) --output=$@ --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
+$(outdir)/%/index.html: $(outdir)/%.texi
+ mkdir -p $(dir $@)
+ $(MAKEINFO) -I $(outdir) --output=$(dir $@) --css-include=$(top-src-dir)/Documentation/texinfo.css --html $<
$(outdir)/%.pdf: $(outdir)/%.texi
cd $(outdir); texi2pdf $(TEXI2PDF_FLAGS) --batch $(TEXINFO_PAPERSIZE_OPTION) $(<F)
# info stuff
INFO_INSTALL_FILES = $(wildcard $(addsuffix *, $(INFO_FILES)))
INFO_INSTALL_COMMAND =$(if $(INFO_INSTALL_FILES),\
- $(INSTALLPY) -d $(DESTDIR)$(package_infodir) ; \
- $(MAKE) INSTALLATION_OUT_DIR=$(package_infodir) \
+ $(INSTALLPY) -d $(DESTDIR)$(infodir) ; \
+ $(MAKE) INSTALLATION_OUT_DIR=$(infodir) \
depth=$(depth) INSTALLATION_OUT_FILES="$(INFO_INSTALL_FILES)" \
-f $(stepdir)/install-out.sub.make,true)