]> git.donarmstrong.com Git - lilypond.git/commitdiff
patch::: 1.3.122.jcn2
authorJan Nieuwenhuizen <janneke@gnu.org>
Wed, 10 Jan 2001 17:35:53 +0000 (18:35 +0100)
committerJan Nieuwenhuizen <janneke@gnu.org>
Wed, 10 Jan 2001 17:35:53 +0000 (18:35 +0100)
1.3.122.jcn2
============

* Doco fixes, included feature document into main documentation.

* lily/chord.cc (member_notename):
     (lower_pitch): gh_member returns a list of which car is
the member!

* Bugfix: added equal_p to list of smob functions.  This fixes
behaviour of property chordChanges.

* More guile-1.4.1 snapshot fixes, generated doco.

29 files changed:
CHANGES
Documentation/header.html.in
Documentation/index.texi
Documentation/user/GNUmakefile
Documentation/user/convert-ly.itexi
Documentation/user/development.itexi
Documentation/user/features.itely [new file with mode: 0644]
Documentation/user/features.tely
Documentation/user/lilypond.tely
Documentation/user/ly2dvi.itexi [new file with mode: 0644]
Documentation/user/ly2dvi.texi
Documentation/user/macros.itexi [new file with mode: 0644]
Documentation/user/midi2ly.itexi [new file with mode: 0644]
Documentation/user/midi2ly.texi
Documentation/user/programs.itexi [new file with mode: 0644]
Documentation/user/refman.itely
Documentation/user/tutorial.itely
VERSION
input/bugs/chord-changes.ly
input/test/chord-changes.ly
lily/chord-name-engraver.cc
lily/chord.cc
lily/include/ly-smobs.icc
scm/backend-documentation-lib.scm
scm/documentation-lib.scm
scm/engraver-documentation-lib.scm
scm/generate-documentation.scm
scm/interface-description.scm
scm/standalone.scm

diff --git a/CHANGES b/CHANGES
index 41c544017befbaeabe9ab5d8f7b31a4701b8ebc6..cae6c3ae8cf0af75694a9195662343b5bfc6b494 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,9 +1,24 @@
+1.3.122.jcn2
+============
+
+* Doco fixes, included feature document into main documentation.
+
+* lily/chord.cc (member_notename):
+               (lower_pitch): gh_member returns a list of which car is
+the member!
+
+* Bugfix: added equal_p to list of smob functions.  This fixes
+behaviour of property chordChanges.
+
+* More guile-1.4.1 snapshot fixes, generated doco.
+
 1.3.122.jcn1
 ============
 
 * Doco fixes.
 
-* Small fixes for guile-1.4.1 snapshot.
+* Small fixes for guile-1.4.1 snapshot which is more strict on symbols
+vs strings.
 
 1.3.121.hwn1
 ============
@@ -3456,5 +3471,8 @@ pl 15.hwn1
 
 pl 15.jcn4
        - direct #... to scm parser  (Thanks to Gary Houston)
-
+Local variables:
+mode: change-log
+left-margin: 0
+End:
 
index bb84e2874b836a1e1226f7489a0b7434aa058b53..e23d7c22f92a6831b6fa7fdc45af078c2f9ac0ad 100644 (file)
@@ -52,7 +52,6 @@ which substitutes some @AT_VARIABLES@ as well.
        <a href="@TOP@Documentation/topdocs/out-www/FAQ.html">Small FAQ</a><br>
        <a href="http://appel.lilypond.org/wiki?LilyPondFaqs">Full FAQ</a><br>
        <a href="@TOP@Documentation/user/out-www/lilypond/lilypond.html">User manual</a><br>
-       <a href="@TOP@Documentation/user/out-www/features/features.html">Features</a><br>
        <a href="@TOP@Documentation/out-www/regression-test.html">Regression Test</a><br>
        <a href="http://appel.lilypond.org/wiki?LilyPondToDo">To do</a><br>
 <br>
index 9dde8b5dec13ef5f8b93f22c264786d4fe24679b..8c25bba5957eae9a9e8fc512013e7c698148f3c2 100644 (file)
 @unnumberedsubsec Manuals
 
 @itemize @bullet
-@item @uref{../user/out-www/lilypond/lilypond.html,LilyPond reference manual}
+@item @uref{../user/out-www/lilypond/lilypond.html,LilyPond user manual}
+@item @uref{../user/out-www/lilypond/Reference-Manual.html,LilyPond reference manual}
 also available in @uref{../user/out-www/lilypond.ps.gz,Postscript}
 @item LilyPond @uref{../user/out-www/lilypond-internals/lilypond-internals.html,internals}
-@item @uref{../user/out-www/features/features.html, LilyPond features}
+@item @uref{../user/out-www/lilypond/Features.html, LilyPond features}
 work in progress, to me merged with reference manual.
 @item @uref{../user/out-www/glossary.html,A glossary of musical
 terms}, includes translations.  Also available in @uref{../user/out-www/glossary.ps.gz,Postscript})
index 5c6310c150cd93e3a16bd3739a74a1f5611de5e9..422e5bfc13a52144d2d60b0f35dd4cb47530b536 100644 (file)
@@ -61,15 +61,9 @@ $(outdir)/lilypond-internals/lilypond-internals.html: $(outdir)/lilypond-interna
        -cp -f $(outdir)/lilypond-internals/index.html $@
        $(deep-footify) $(shell find $(outdir)/$(*F)/*.html)
 
-$(outdir)/features/features.html: $(outdir)/features.texi
-       -$(MAKEINFO) --force --output=$@ --html $<
-       -cp -f $(outdir)/*.png $(outdir)/features
-       -cp -f $(outdir)/features/index.html $@
-       $(deep-footify) $(shell find $(outdir)/$(*F)/*.html)
-
 ifneq ($(SPLITTING_MAKEINFO),)
 
-DEEP_HTML_FILES = $(outdir)/lilypond/lilypond.html $(outdir)/lilypond-internals/lilypond-internals.html $(outdir)/features/features.html
+DEEP_HTML_FILES = $(outdir)/lilypond/lilypond.html $(outdir)/lilypond-internals/lilypond-internals.html
 
 else
 
@@ -79,7 +73,7 @@ endif
 
 
 local-WWW: $(HTML_FILES) $(datafiles) $(PS_GZ_FILES) $(DEEP_HTML_FILES)
-       $(SHELL) $(buildscript-dir)/install-info-html.sh --dir=$(outdir) lilypond lilypond-internals features
+       $(SHELL) $(buildscript-dir)/install-info-html.sh --dir=$(outdir) lilypond lilypond-internals
        $(MAKE) footify
        $(MAKE) deep-footify
 
@@ -96,7 +90,7 @@ $(outdir)/%.bib: %.bib
 
 localclean:
        rm -f fonts.aux fonts.log feta*.tfm feta*.*pk 
-       rm -rf $(outdir)/lilypond $(outdir)/lilypond-internals $(outdir)/features
+       rm -rf $(outdir)/lilypond $(outdir)/lilypond-internals
 
 backdoc-WWW: $(outdir)/lilypond-internals/lilypond-internals.html
        $(SHELL) $(buildscript-dir)/install-info-html.sh --dir=$(outdir) lilypond lilypond-internals
index d8cda19993591641de4b651b98fdee07bce6613b..1b8bf18726a5c70cc8433e4cc43599edfe96c6e7 100644 (file)
@@ -1,17 +1,21 @@
-@node convert-ly
-@chapter convert-ly
+@c -*-texinfo-*-
 
+@node Convert-ly
+@section Convert-ly
 
-@code{convert-ly} sequentially applies different
+
+Convert-ly sequentially applies different
 lilypond-conversions to upgrade a Lilypond input file.  It uses
 @code{\version} statements in the file to detect the old version
 number.
 
+@subsection Invoking convert-ly
+
 @example
         convert-ly [options] [files]
 @end example
 
-@section Options
+
 @table @samp
 @item --output
     The output file to write.  
index 0de65f4d4569dae33b365f3db6a179bc64433010..d21699b48b97e148346bfe05213c89f09495d585 100644 (file)
@@ -1,3 +1,6 @@
+@c -*-texinfo-*-
+
+@c Move chapter
 @node Internals
 @chapter Internals
 
@@ -120,9 +123,8 @@ to. Whenever the note head is moved, the staccato dot moves along
 automatically.
 
 If you keep following offset reference points, you will always end up at
-the root-object. This root object is called @code{Line_of_score}
-@ref{(lilypond-internals)Element Line_of_score}, and it represents a
-system (ie. a line of music).
+the root-object. This root object is called @rgrob{Line_of_score}, and it
+represents a system (ie. a line of music).
 
 All grobs carry a set of grob-properties.  In the Stem example above,
 the property @code{direction} is set to value @code{1}.  The function
@@ -134,13 +136,12 @@ properties.
 Often, a grob also is associated with a symbol. On the other hand,
 Some grobs do not print any symbols, but take care of grouping
 objects. For example, there is a separate grob that stacks staffs
-vertically, so they are not printed in overstrike. The NoteCollision
-@ref{(lilypond-internals)Element NoteCollision} is another example of
-an abstract grob.  It only moves around chords, but doesn't print
-anything.
+vertically, so they are not printed in overstrike. The
+@rgrob{NoteCollision} is another example of an abstract grob.  It only
+moves around chords, but doesn't print anything.
 
 A complete list of grob types is found in
-@ref{(lilypond-internals)Elements}
+@ref{(lilypond-internals)LilyPond backend}
 
 Grobs are created in the "Interpreting music" phase, by things in
 LilyPond called engravers.  In this phase of the translation, a load of
diff --git a/Documentation/user/features.itely b/Documentation/user/features.itely
new file mode 100644 (file)
index 0000000..fa5034e
--- /dev/null
@@ -0,0 +1,715 @@
+@ignore
+
+TODO
+  * move some stuff to refman
+  * merge some stuff with refman entries
+  
+  * add @ref{}s to lilypond-internals:
+     @rgrob{Name} to grob
+     @reng{Name} to engraver
+
+  there's a very simple, very general noXXX mechanism; try
+
+noop   \property Staff.VoltaBrace = #'()
+yes: \property Staff.VoltaBracket = #'((meta .  ((interfaces . ()))))
+
+
+  visibility?
+  brew_molecule?
+@end ignore
+
+
+@node Features
+@chapter Features
+
+@menu
+* Arpeggio::                       Arpeggio
+* Glissando::                      Glissando
+* Manual beam settings::           Manual beam settings
+* Slur attachments::               Slur attachments
+* Text spanner::                   Text spanner
+* Engraver hacking::               Engraver hacking
+* Part combiner::                  Part combiner
+* Markup text::                    Markup text
+* Apply hacking::                  Apply hacking
+* Output property::                Output property
+* Embedded TeX::                   Embedded TeX
+* Embedded PostScript::            Embedded PostScript
+@c * Index::                          Checking Feature index
+@end menu
+
+
+@node Arpeggio
+@section Arpeggio
+@cindex argepeggio
+
+@cindex broken arpeggio
+
+You can specify an @rgrob{Arpeggio} sign on a chord by issuing an
+@c FIXME
+@c @code{\arpeggio}@indexcode{\arpeggio} request:
+@code{\arpeggio} request:
+
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \context Voice <c'\arpeggio e g c>
+@end lilypond
+@end quotation
+
+Typesetting of simultanious chords with arpeggios can be controlled with
+the property @code{PianoStaff.connectArpeggios} @footnote{ FIXME:
+connectArpeggios.  Can't find the English terms for two kinds of
+arpeggio (Dutch: gebroken arpeggio vs doorlopend arpeggio).}  By
+default, LilyPond prints broken arpeggios; when set to true, one
+extended arpeggio sign is printed.
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \context PianoStaff <
+    \property PianoStaff.connectArpeggios = ##t
+    \context Staff \context Voice <c''\arpeggio e g c>
+    \context Staff=other \context Voice <c,\arpeggio e g>
+  >  
+@end lilypond
+@end quotation
+
+@node Glissando
+@section Glissando
+@cindex glissando
+
+A @rgrob{Glissando} line can be requested by issuing a
+@c FIXME
+@c @code{\glissando}@indexcode{\glissando} request:
+@code{\glissando} request:
+
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  c'' \glissando c'
+@end lilypond
+@end quotation
+
+Printing of the additional text @samp{gliss.} is currently not
+supported.
+
+
+@subsection Follow Thread
+@cindex follow thread
+@cindex staff switching
+@cindex cross staff
+
+@c Documented here because it looks like a glissando...
+A glissando-like line can be printed to connect notes whenever a thread
+switches to another staff.  This is enabled if the property
+@code{PianoStaff.followThread}@indexcode{followThread} is set to true:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \context PianoStaff <
+    \property PianoStaff.followThread = ##t
+    \context Staff \context Voice {
+      c'1
+      \translator Staff=two
+      b2 a
+    }
+    \context Staff=two {\clef bass; \skip 1*2;}
+  >  
+@end lilypond
+@end quotation
+
+@node Manual beam settings
+@section Manual beam settings
+@cindex beams
+@cindex beam settings
+@cindex manual beams
+
+In some cases it may be necessary to override LilyPond's automatic
+beaming algorithm.  For example, the auto beamer will not beam over
+rests, so if you want that, specify the begin and end point manually
+using @code{[}@indexcode{[} and @code{]}@indexcode{]}:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \context Staff {
+    r4 [r8 g'' a]
+  }
+@end lilypond
+@end quotation
+
+Similarly, for beams over bar lines:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \context Staff {
+    a''8 r a2 r8 [a a]
+  }
+@end lilypond
+@end quotation
+
+If you have specific wishes for the number of beams, you can fully
+control the number of beams through the properties
+@code{Voice.stemLeftBeamCount}@indexcode{stemLeftBeamCount};
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \context Staff {
+    [f'8 r16 f g a]
+    [f8 r16 \property Voice.stemLeftBeamCount = #1 f g a]
+  }
+@end lilypond
+@end quotation
+
+and @code{Voice.stemRightBeamCount}@indexcode{stemRightBeamCount}:
+@quotation
+@lilypond[fragment,relative,verbatim]
+  f'32 g a b b a g f
+
+  \property Voice.autoBeamSettings
+    \set #'(end * * * *) = #(make-moment 1 4)
+  f32 g a b b a g f
+
+  f32 g a
+  \property Voice.stemRightBeamCount = #1 b
+  \property Voice.stemLeftBeamCount = #1 b
+  a g f
+@end lilypond
+@end quotation
+
+Conventionally, stems extend to the middle staff line, and thus so do
+beams.  The extending of the stems can be controlled through 
+@code{Voice.Stem}'s grob-property
+@code{no-stem-extend}@indexcode{no-stem-extend}:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \grace a'8 a4
+  \property Voice.Stem \set #'no-stem-extend = ##t
+  \grace g8 g4 [g8 g]
+@end lilypond
+@end quotation
+
+The beam symbol can be tweaked through @code{Voice.Beam}'s
+grob-properties @code{height-hs} and @code{y-position-hs}.
+
+Set @code{height-hs} to zero, to get horizontal beams:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \property Voice.Beam \set #'direction = #1
+  \property Voice.Beam \set #'height-hs = #0
+  [a''8 e' d c]
+@end lilypond
+@end quotation
+
+Both are in half spaces.  Here's how you'd specify a weird looking beam
+that instead of beaing horizontal, falls two staff spaces (ie, four half
+spaces):
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \property Voice.Beam \set #'y-position-hs = #4
+  \property Voice.Beam \set #'height-hs = #-4
+  [c'8 c] 
+@end lilypond
+@end quotation
+
+The direction of a perfectly centred beams can be
+controlled through @code{Voice.Beam}'s grob-property
+@code{default-neutral-direction}@indexcode{default-neutral-direction}
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  [b''8 b]
+  \property Voice.Beam \set #'default-neutral-direction = #-1
+  [b b]
+@end lilypond
+@end quotation
+
+There are several ways to calculate the direction of a beam.
+
+[Ross] states that the majority of the notes dictates the
+direction (and not the mean of "center distance")
+
+But is that because it really looks better, or because he wants
+to provide some real simple hands-on rules?
+     
+We have our doubts, so we simply provide all sensible alternatives:
+
+@table @samp
+@item majority
+number count of up or down notes
+@item mean
+mean centre distance of all notes
+@item median
+mean centre distance weighted per note
+@end table
+
+You can spot the differences of these settings from these simple
+examples:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  [d''8 a]
+  \property Voice.Beam \set #'dir-function = #beam-dir-mean
+  [d a] 
+  \property Voice.Beam \set #'dir-function = #beam-dir-median
+  [d a]
+@end lilypond
+@end quotation
+
+@quotation    
+@lilypond[fragment,relative,verbatim]
+  \time 3/8;
+  [d''8 a a]
+  \property Voice.Beam \set #'dir-function = #beam-dir-mean
+  [d a a] 
+  \property Voice.Beam \set #'dir-function = #beam-dir-median
+  [d a a] 
+@end lilypond
+@end quotation
+
+These beam direction functions are defined in @file{scm/beam.scm}.  If
+your favourite algorithm isn't one of these, you can hook up your own.
+
+
+
+@node Slur attachments
+@section Slur attachments
+
+The ending of a slur should whenever possible be attached to a note
+head.  Only in some instances where beams are involved, LilyPond may
+attach a slur to a stem end.  In some cases, you may want to override
+LilyPond's decision, eg to attach the slur to the stem end.  This can be
+done through @code{Voice.Slur}'s grob-property @code{attachment}:
+@c FIXME: make @ref{} to backend doco
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \property Voice.Slur \set #'direction = #1
+  \property Voice.Stem \set #'length = #5.5
+  g''8(g)g4
+  g4(g8)g
+  \property Voice.Slur \set #'attachment = #'(stem . stem)
+  g8(g)g4
+  g4(g8)g
+@end lilypond
+@end quotation
+
+Trying Before | After example...
+@c Fix rolled into 4.0a prerelease
+@c is this nice?
+
+@multitable @columnfractions .40 .40
+@item
+@noindent
+@lilypond[fragment,relative,verbatim]
+\property Voice.Slur
+  \set #'direction = #1
+g''8(g)g4
+g4(g8)g
+@end lilypond
+@tab
+@lilypond[fragment,relative,verbatim]
+\property Voice.Slur
+  \set #'direction = #1
+\property Voice.Stem
+  \set #'length = #5.5
+\property Voice.Slur
+  \set #'attachment = #'(stem . stem)
+g''8(g)g4
+g4(g8)g
+@end lilypond
+@end multitable
+
+
+Similarly, slurs can be attached to note heads even when beams are
+involved (aka Ophee slurs):
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \property Voice.Slur \set #'direction = #1
+  \property Voice.Slur \set #'attachment = #'(head . head)
+  g''16()g()g()g()d'()d()d()d
+@end lilypond
+@end quotation
+
+If a slur would strike through a stem or beam, LilyPond will move the
+slur away vertically (upward or downward).  In some cases, this may
+cause ugly slurs that you may want to correct:
+
+@quotation
+@lilypond[fragment,relative,verbatim]
+  \property Voice.Stem \set #'direction = #1
+  \property Voice.Slur \set #'direction = #1
+  d'32( d'4 )d8..
+  \property Voice.Slur \set #'attachment = #'(stem . stem)
+  d,32( d'4 )d8..
+@end lilypond
+@end quotation
+
+LilyPond will increase the curvature of a slur trying to stay free of
+note heads and stems.  However, if the curvature would increase too much,
+the slur will be reverted to its default shape.  This decision is based
+on @code{Voice.Slur}'s grob-property @code{beautiful} value.  In some
+cases, you may find ugly slurs beautiful, and tell LilyPond so by
+increasing the @code{beautiful} value:
+
+@quotation
+@lilypond[verbatim]
+\score {
+  \notes \context PianoStaff <
+    \time 6/4;
+    \context Staff=up { s1 * 6/4 }
+    \context Staff=down <
+      \clef bass;
+      \autochange Staff \context Voice
+        \notes \relative c {
+          d,8( a' d f a d f d a f d )a
+        }
+    >
+  >
+  \paper {
+    linewidth = -1.;
+    \translator {
+      \VoiceContext
+      Slur \override #'beautiful = #5.0
+      Slur \override #'direction = #1
+      Stem \override #'direction = #-1
+      autoBeamSettings \override #'(end * * * *)
+        = #(make-moment 1 2)
+    }
+    \translator {
+      \PianoStaffContext
+      VerticalAlignment \override #'threshold = #'(5 . 5)
+    }
+  }
+}
+@end lilypond
+@end quotation
+
+
+@node Text spanner
+@section Text spanner
+
+
+
+Have crescendo set a text spanner iso hairpin
+
+
+@lilypond[fragment,relative,verbatim]
+  \context Voice {
+    \property Voice.crescendoText = "cresc."
+    \property Voice.crescendoSpanner = #'dashed-line
+    a''2\mf\< a a \!a 
+  }
+@end lilypond
+
+@subsection Ottava
+
+@lilypond[fragment,relative,verbatim]
+  a'''' b c a
+  \property Voice.TextSpanner \set #'type = #'dotted-line
+  \property Voice.TextSpanner \set #'edge-height = #'(0 . 1.5)
+  \property Voice.TextSpanner \set #'edge-text = #'("8va " . "")
+  \property Staff.centralCPosition = #-13
+  a\spanrequest \start "text" b c a \spanrequest \stop "text"
+@end lilypond
+
+
+
+@node Engraver hacking
+@section Engraver hacking
+
+No time signature, no barlines... 
+@lilypond[verbatim]
+\score {
+  \notes \relative c'' {
+    a b c d
+    d c b a
+  }
+  \paper {
+    linewidth = -1.;
+    \translator {
+      \StaffContext
+      whichBar = #""
+      \remove "Time_signature_engraver";
+    }
+  }
+}
+@end lilypond
+
+No staff, no clef, squash pitches
+@lilypond[verbatim]
+\score {
+  \notes { c4 c4 c8 c8 }
+  \paper {
+    linewidth = -1.;
+    \translator {
+      \StaffContext
+      \remove Staff_symbol_engraver;
+      \consists Pitch_squash_engraver;
+      \remove Clef_engraver;
+    }
+  }
+}
+@end lilypond
+
+
+@node Part combiner
+@section Part combiner
+
+@lilypond[verbatim]
+\score{
+  \context Staff = flauti <
+    \time 4/4;
+    \context Voice=one \partcombine Voice
+    \context Thread=one \notes\relative c'' {
+      c4 d e f | b,4 d c d | r2 e4 f | c4 d e f |
+      c4 r e f | c4 r e f | c4 r a r | a a r a |
+      a2 \property Voice.soloADue = ##f a |
+    }
+    \context Thread=two \notes\relative c'' {
+      g4 b d f | r2 c4 d | a c c d | a4. b8 c4 d
+      c r e r | r2 s2 | a,4 r a r | a r r a |
+      a2 \property Voice.soloADue = ##f a |
+    }
+  >
+  \paper{
+    linewidth = 80 * \staffspace;
+    \translator{
+      \ThreadContext
+      \consists Rest_engraver;
+    }
+    \translator{
+      \VoiceContext
+      \remove Rest_engraver;
+    }
+  }
+}
+@end lilypond
+
+
+
+
+@node Markup text
+@section Markup text
+
+Metrome hack...
+
+
+
+@lilypond[verbatim]
+#(define note '(rows (music "noteheads-2" ((kern . -0.1) "flags-stem"))))
+#(define eight-note `(rows ,note ((kern . -0.1) (music ((raise . 3.5) "flags-u3")))))
+#(define dotted-eight-note `(rows ,eight-note (music "dots-dot")))
+
+\score {
+  \notes\relative c'' {
+    a1^#`(rows ,dotted-eight-note " = 64")
+  }
+  \paper {
+    linewidth = -1.;
+    \translator{
+      \ScoreContext
+      TextScript \override #'font-shape = #'upright
+    }
+  }
+}
+@end lilypond
+
+
+@node Output property
+@section Output property
+
+@lilypond[fragment,relative,verbatim]
+    \outputproperty #(make-type-checker 'note-head-interface) 
+      #'extra-offset = #'(2 . 3)
+    c''2 c
+@end lilypond
+
+Don't move the finger 2, only text "m.d." ...
+@lilypond[verbatim]
+#(define (make-text-checker text)
+   (lambda (grob) (equal? text (ly-get-elt-property grob 'text))))
+
+\score {    
+  \notes\relative c''' {
+    \property Voice.Stem \set #'direction = #1
+    \outputproperty #(make-text-checker "m.d.")
+      #'extra-offset = #'(-3.5 . -4.5)
+    a^2^"m.d."    
+  }
+  \paper { linewidth = -1.; }
+}
+@end lilypond
+
+
+@c  equalizer
+
+
+@node Apply hacking
+@section Apply hacking
+
+@lilypond[verbatim]
+music = \notes { c'4 d'4( e'4 f'4 }
+
+#(define (reverse-music music)
+  (let* ((elements (ly-get-mus-property music 'elements))
+        (reversed (reverse elements))
+        (span-dir (ly-get-mus-property music 'span-direction)))
+    
+    (ly-set-mus-property music 'elements reversed)
+    
+    (if (dir? span-dir)
+       (ly-set-mus-property music 'span-direction (- span-dir)))
+    
+    (map reverse-music reversed)
+    
+    music))
+
+\score {
+  \context Voice {
+    \music
+    \apply #reverse-music \music
+  }
+  \paper { linewidth = -1.; }
+}
+@end lilypond
+
+
+LilyPond is more flexible than some users realise.  Han-Wen could be
+very rich.
+
+Just too funny not to include.
+
+@example
+@quotation
+    I've just entered a request on cosource.com :
+@quotation
+        http://www.cosource.com/cgi-bin/cos.pl/wish/info/387
+@end quotation
+    Here's a copy of my feature request :
+@quotation
+        Your task, if you accept it is to implement a \smarttranspose
+        command> that would translate such oddities into more natural
+        notations. Double accidentals should be removed, as well as #E
+        (-> F), bC (-> B), bF (-> E), #B (-> C).
+@end quotation
+@end quotation
+You mean like this. (Sorry 'bout the nuked indentation.)
+
+Add IMPLEMENT_TYPE_P(Music, "music?"); to music.cc, and presto, done.
+
+That's an easy $ 100; if I'd make $ 200/hour for every hour I worked
+on Lily, I'd be very rich :)
+@end example
+
+
+@lilypond[verbatim]
+#(define  (unhair-pitch p)
+  (let* ((o (pitch-octave p))
+         (a (pitch-alteration p))
+        (n (pitch-notename p)))
+
+    (cond
+     ((and (> a 0) (or (eq? n 6) (eq? n 2)))
+      (set! a (- a 1)) (set! n (+ n 1)))
+     ((and (< a 0) (or (eq? n 0) (eq? n 3)))
+      (set! a (+ a 1)) (set! n (- n 1))))
+    
+    (cond
+     ((eq? a 2)  (set! a 0) (set! n (+ n 1)))
+     ((eq? a -2) (set! a 0) (set! n (- n 1))))
+
+    (if (< n 0) (begin (set!  o (- o 1)) (set! n (+ n 7))))
+    (if (> n 7) (begin (set!  o (+ o 1)) (set! n (- n 7))))
+    
+    (make-pitch o n a)))
+
+#(define (smart-transpose music pitch)
+  (let* ((es (ly-get-mus-property music 'elements))
+        (e (ly-get-mus-property music 'element))
+        (p (ly-get-mus-property music 'pitch))
+        (body (ly-get-mus-property music 'body))
+        (alts (ly-get-mus-property music 'alternatives)))
+
+    (if (pair? es)
+       (ly-set-mus-property
+        music 'elements
+        (map (lambda (x) (smart-transpose x pitch)) es)))
+    
+    (if (music? alts)
+       (ly-set-mus-property
+        music 'alternatives
+        (smart-transpose alts pitch)))
+    
+    (if (music? body)
+       (ly-set-mus-property
+        music 'body
+        (smart-transpose body pitch)))
+
+    (if (music? e)
+       (ly-set-mus-property
+        music 'element
+        (smart-transpose e pitch)))
+    
+    (if (pitch? p)
+       (begin
+         (set! p (unhair-pitch (Pitch::transpose p pitch)))
+         (ly-set-mus-property music 'pitch p)))
+    
+    music))
+
+    
+music = \notes \relative c' { c4 d  e f g a b  c }
+
+\score {
+  \notes \context Staff {
+    \transpose ais' \music
+    \apply #(lambda (x) (smart-transpose x (make-pitch 0 5 1)))
+      \music
+  }
+  \paper { linewidth = -1.; }
+}
+@end lilypond
+
+
+@node Embedded TeX
+@section Embedded TeX
+@lilypond[fragment,relative,verbatim]
+  a''^"3 $\\times$ \\`a deux"
+@end lilypond
+
+@node Embedded PostScript
+@section Embedded PostScript
+
+Arbitrary lines and curves not supported...
+
+[TODO:] Make a direct postscript command?
+
+@lilypond[verbatim]
+\score {
+  \notes \relative c'' {
+    a-#"\\embeddedps{3 4 moveto 5 3 rlineto stroke}"
+    -#"\\embeddedps{ [ 0 1 ] 0 setdash 3 5 moveto 5 -3 rlineto stroke}"
+    b-#"\\embeddedps{3 4 moveto 0 0 1 2 8 4 20 3.5 rcurveto stroke}"
+    s2
+    a'1
+  }
+  \paper { linewidth = 70 * \staffspace; }
+}
+@end lilypond
+
+@ignore 
+@node Index
+@section Checking Feature index
+
+@printindex cp
+
+
+@bye
+@end ignore
+
+
index 694729a70a4181aeefec419581e17beedde2db23..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 100644 (file)
@@ -1,725 +0,0 @@
-\input texinfo @c -*-texinfo-*-
-@setfilename features.info
-@settitle GNU LilyPond Features
-
-@ignore
-TODO
-  * add more un/badly documented features
-  * write some text
-  * add to/merge with refman
-
-
-  
-  there's a very simple, very general noXXX mechanism; try
-
-noop   \property Staff.VoltaBrace = #'()
-yes: \property Staff.VoltaBracket = #'((meta .  ((interfaces . ()))))
-
-
-  visibility?
-  brew_molecule?
-@end ignore
-
-
-@macro keyindex {word}
-@cindex \word\
-
-@end macro
-
-@macro indexcode {word}
-@cindex \word\
-
-@end macro
-
-
-
-@node Top
-@chapter Features
-
-@menu
-* Arpeggio::                       Arpeggio
-* Glissando::                      Glissando
-* Manual beam settings::           Manual beam settings
-* Slur attachments::               Slur attachments
-* Text spanner::                   Text spanner
-* Engraver hacking::               Engraver hacking
-* Part combiner::                  Part combiner
-* Markup text::                    Markup text
-* Apply hacking::                  Apply hacking
-* Output property::                Output property
-* Embedded TeX::                   Embedded TeX
-* Embedded PostScript::            Embedded PostScript
-* Index::                          Checking Feature index
-@end menu
-
-@node Arpeggio
-@section Arpeggio
-@cindex argepeggio
-
-@cindex broken arpeggio
-@c @cindex ``doorlopend'' argpeggio
-
-You can specify an arpeggio sign on a chord by issuing an
-@c duh
-@c @code{\arpeggio}@indexcode{\arpeggio} request:
-@code{\arpeggio} request:
-@cindex @code{\arpeggio}
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \context Voice <c'\arpeggio e g c>
-@end lilypond
-@end quotation
-
-Typesetting of simultanious chords with arpeggios can be controlled with
-the property @code{PianoStaff.connectArpeggios} @footnote{ FIXME:
-connectArpeggios.  Can't find the English terms for two kinds of
-arpeggio (Dutch: gebroken arpeggio vs doorlopend arpeggio).}  By
-default, LilyPond prints broken arpeggios; when set to true, one
-extended arpeggio sign is printed.
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \context PianoStaff <
-    \property PianoStaff.connectArpeggios = ##t
-    \context Staff \context Voice <c''\arpeggio e g c>
-    \context Staff=other \context Voice <c,\arpeggio e g>
-  >  
-@end lilypond
-@end quotation
-
-@node Glissando
-@section Glissando
-@cindex glissando
-
-A glissando line can be requested by issuing a
-@c duh
-@c @code{\glissando}@indexcode{\glissando} request:
-@code{\glissando} request:
-@cindex @code{\glissando}
-
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  c'' \glissando c'
-@end lilypond
-@end quotation
-
-Printing of the additional text @code{"gliss."} is currently not
-supported.
-
-
-@subsection Follow Thread
-@cindex follow thread
-@cindex staff switching
-@cindex cross staff
-
-@c Documented here because it looks like a glissando.
-A glissando-like line can be printed to connect notes whenever a thread
-switches to another staff.  This is enabled if the property
-@code{PianoStaff.followThread}@indexcode{followThread} is set to true:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \context PianoStaff <
-    \property PianoStaff.followThread = ##t
-    \context Staff \context Voice {
-      c'1
-      \translator Staff=two
-      b2 a
-    }
-    \context Staff=two {\clef bass; \skip 1*2;}
-  >  
-@end lilypond
-@end quotation
-
-@node Manual beam settings
-@section Manual beam settings
-@cindex beams
-@cindex beam settings
-@cindex manual beams
-
-In some cases it may be necessary to override LilyPond's automatic
-beaming algorithm.  For example, the auto beamer will not beam over
-rests, so if you want that, specify the begin and end point manually
-using @code{[}@indexcode{[} and @code{]}@indexcode{]}:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \context Staff {
-    r4 [r8 g'' a]
-  }
-@end lilypond
-@end quotation
-
-Similarly, for beams over bar lines:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \context Staff {
-    a''8 r a2 r8 [a a]
-  }
-@end lilypond
-@end quotation
-
-If you have specific wishes for the number of beams, you can fully
-control the number of beams through the properties
-@code{Voice.stemLeftBeamCount}@indexcode{stemLeftBeamCount};
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \context Staff {
-    [f'8 r16 f g a]
-    [f8 r16 \property Voice.stemLeftBeamCount = #1 f g a]
-  }
-@end lilypond
-@end quotation
-
-and @code{Voice.stemRightBeamCount}@indexcode{stemRightBeamCount}:
-@quotation
-@lilypond[fragment,relative,verbatim]
-  f'32 g a b b a g f
-
-  \property Voice.autoBeamSettings
-    \set #'(end * * * *) = #(make-moment 1 4)
-  f32 g a b b a g f
-
-  f32 g a
-  \property Voice.stemRightBeamCount = #1 b
-  \property Voice.stemLeftBeamCount = #1 b
-  a g f
-@end lilypond
-@end quotation
-
-Conventionally, stems extend to the middle staff line, and thus so do
-beams.  The extending of the stems can be controlled through 
-@code{Voice.Stem}'s grob-property
-@code{no-stem-extend}@indexcode{no-stem-extend}:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \grace a'8 a4
-  \property Voice.Stem \set #'no-stem-extend = ##t
-  \grace g8 g4 [g8 g]
-@end lilypond
-@end quotation
-
-The beam symbol can be tweaked through @code{Voice.Beam}'s
-grob-properties @code{height-hs} and @code{y-position-hs}.
-
-Set @code{height-hs} to zero, to get horizontal beams:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \property Voice.Beam \set #'direction = #1
-  \property Voice.Beam \set #'height-hs = #0
-  [a''8 e' d c]
-@end lilypond
-@end quotation
-
-Both are in half spaces.  Here's how you'd specify a weird looking beam
-that instead of beaing horizontal, falls two staff spaces (ie, four half
-spaces):
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \property Voice.Beam \set #'y-position-hs = #4
-  \property Voice.Beam \set #'height-hs = #-4
-  [c'8 c] 
-@end lilypond
-@end quotation
-
-The direction of a perfectly centred beams can be
-controlled through @code{Voice.Beam}'s grob-property
-@code{default-neutral-direction}@indexcode{default-neutral-direction}
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  [b''8 b]
-  \property Voice.Beam \set #'default-neutral-direction = #-1
-  [b b]
-@end lilypond
-@end quotation
-
-There are several ways to calculate the direction of a beam.
-
-[Ross] states that the majority of the notes dictates the
-direction (and not the mean of "center distance")
-
-But is that because it really looks better, or because he wants
-to provide some real simple hands-on rules?
-     
-We have our doubts, so we simply provide all sensible alternatives:
-
-@table @samp
-@item majority
-number count of up or down notes
-@item mean
-mean centre distance of all notes
-@item median
-mean centre distance weighted per note
-@end table
-
-You can spot the differences of these settings from these simple
-examples:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  [d''8 a]
-  \property Voice.Beam \set #'dir-function = #beam-dir-mean
-  [d a] 
-  \property Voice.Beam \set #'dir-function = #beam-dir-median
-  [d a]
-@end lilypond
-@end quotation
-
-@quotation    
-@lilypond[fragment,relative,verbatim]
-  \time 3/8;
-  [d''8 a a]
-  \property Voice.Beam \set #'dir-function = #beam-dir-mean
-  [d a a] 
-  \property Voice.Beam \set #'dir-function = #beam-dir-median
-  [d a a] 
-@end lilypond
-@end quotation
-
-These beam direction functions are defined in @file{scm/beam.scm}.  If
-your favourite algorithm isn't one of these, you can hook up your own.
-
-
-
-@node Slur attachments
-@section Slur attachments
-
-The ending of a slur should whenever possible be attached to a note
-head.  Only in some instances where beams are involved, LilyPond may
-attach a slur to a stem end.  In some cases, you may want to override
-LilyPond's decision, eg to attach the slur to the stem end.  This can be
-done through @code{Voice.Slur}'s grob-property @code{attachment}:
-@c FIXME: make @ref{} to backend doco
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \property Voice.Slur \set #'direction = #1
-  \property Voice.Stem \set #'length = #5.5
-  g''8(g)g4
-  g4(g8)g
-  \property Voice.Slur \set #'attachment = #'(stem . stem)
-  g8(g)g4
-  g4(g8)g
-@end lilypond
-*@end quotation
-
-Trying Before | After example...
-@c Fix rolled into 4.0a prerelease
-
-@multitable @columnfractions .40 .40
-@item
-@noindent
-@lilypond[fragment,relative,verbatim]
-\property Voice.Slur
-  \set #'direction = #1
-g''8(g)g4
-g4(g8)g
-@end lilypond
-@tab
-@lilypond[fragment,relative,verbatim]
-\property Voice.Slur
-  \set #'direction = #1
-\property Voice.Stem
-  \set #'length = #5.5
-\property Voice.Slur
-  \set #'attachment = #'(stem . stem)
-g''8(g)g4
-g4(g8)g
-@end lilypond
-@end multitable
-
-
-Similarly, slurs can be attached to note heads even when beams are
-involved (aka Ophee slurs):
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \property Voice.Slur \set #'direction = #1
-  \property Voice.Slur \set #'attachment = #'(head . head)
-  g''16()g()g()g()d'()d()d()d
-@end lilypond
-@end quotation
-
-If a slur would strike through a stem or beam, LilyPond will move the
-slur away vertically (upward or downward).  In some cases, this may
-cause ugly slurs that you may want to correct:
-
-@quotation
-@lilypond[fragment,relative,verbatim]
-  \property Voice.Stem \set #'direction = #1
-  \property Voice.Slur \set #'direction = #1
-  d'32( d'4 )d8..
-  \property Voice.Slur \set #'attachment = #'(stem . stem)
-  d,32( d'4 )d8..
-@end lilypond
-@end quotation
-
-LilyPond will increase the curvature of a slur trying to stay free of
-note heads and stems.  However, if the curvature would increase too much,
-the slur will be reverted to its default shape.  This decision is based
-on @code{Voice.Slur}'s grob-property @code{beautiful} value.  In some
-cases, you may find ugly slurs beautiful, and tell LilyPond so by
-increasing the @code{beautiful} value:
-
-@quotation
-@lilypond[verbatim]
-\score {
-  \notes \context PianoStaff <
-    \time 6/4;
-    \context Staff=up { s1 * 6/4 }
-    \context Staff=down <
-      \clef bass;
-      \autochange Staff \context Voice
-        \notes \relative c {
-          d,8( a' d f a d f d a f d )a
-        }
-    >
-  >
-  \paper {
-    linewidth = -1.;
-    \translator {
-      \VoiceContext
-      Slur \override #'beautiful = #5.0
-      Slur \override #'direction = #1
-      Stem \override #'direction = #-1
-      autoBeamSettings \override #'(end * * * *)
-        = #(make-moment 1 2)
-    }
-    \translator {
-      \PianoStaffContext
-      VerticalAlignment \override #'threshold = #'(5 . 5)
-    }
-  }
-}
-@end lilypond
-@end quotation
-
-
-@node Text spanner
-@section Text spanner
-
-Have crescendo set a text spanner iso hairpin
-@lilypond[fragment,relative,verbatim]
-  \context Voice {
-    \property Voice.crescendoText = "cresc."
-    \property Voice.crescendoSpanner = #'dashed-line
-    a''2\mf\< a a \!a 
-  }
-@end lilypond
-
-@subsection Ottava
-
-@lilypond[fragment,relative,verbatim]
-  a'''' b c a
-  \property Voice.TextSpanner \set #'type = #'dotted-line
-  \property Voice.TextSpanner \set #'edge-height = #'(0 . 1.5)
-  \property Voice.TextSpanner \set #'edge-text = #'("8va " . "")
-  \property Staff.centralCPosition = #-13
-  a\spanrequest \start "text" b c a \spanrequest \stop "text"
-@end lilypond
-
-
-
-@node Engraver hacking
-@section Engraver hacking
-
-No time signature, no barlines... 
-@lilypond[verbatim]
-\score {
-  \notes \relative c'' {
-    a b c d
-    d c b a
-  }
-  \paper {
-    linewidth = -1.;
-    \translator {
-      \StaffContext
-      whichBar = #""
-      \remove "Time_signature_engraver";
-    }
-  }
-}
-@end lilypond
-
-No staff, no clef, squash pitches
-@lilypond[verbatim]
-\score {
-  \notes { c4 c4 c8 c8 }
-  \paper {
-    linewidth = -1.;
-    \translator {
-      \StaffContext
-      \remove Staff_symbol_engraver;
-      \consists Pitch_squash_engraver;
-      \remove Clef_engraver;
-    }
-  }
-}
-@end lilypond
-
-
-@node Part combiner
-@section Part combiner
-
-@lilypond[verbatim]
-\score{
-  \context Staff = flauti <
-    \time 4/4;
-    \context Voice=one \partcombine Voice
-    \context Thread=one \notes\relative c'' {
-      c4 d e f | b,4 d c d | r2 e4 f | c4 d e f |
-      c4 r e f | c4 r e f | c4 r a r | a a r a |
-      a2 \property Voice.soloADue = ##f a |
-    }
-    \context Thread=two \notes\relative c'' {
-      g4 b d f | r2 c4 d | a c c d | a4. b8 c4 d
-      c r e r | r2 s2 | a,4 r a r | a r r a |
-      a2 \property Voice.soloADue = ##f a |
-    }
-  >
-  \paper{
-    linewidth = 80 * \staffspace;
-    \translator{
-      \ThreadContext
-      \consists Rest_engraver;
-    }
-    \translator{
-      \VoiceContext
-      \remove Rest_engraver;
-    }
-  }
-}
-@end lilypond
-
-
-
-
-@node Markup text
-@section Markup text
-
-Metrome hack...
-
-
-
-@lilypond[verbatim]
-#(define note '(rows (music "noteheads-2" ((kern . -0.1) "flags-stem"))))
-#(define eight-note `(rows ,note ((kern . -0.1) (music ((raise . 3.5) "flags-u3")))))
-#(define dotted-eight-note `(rows ,eight-note (music "dots-dot")))
-
-\score {
-  \notes\relative c'' {
-    a1^#`(rows ,dotted-eight-note " = 64")
-  }
-  \paper {
-    linewidth = -1.;
-    \translator{
-      \ScoreContext
-      TextScript \override #'font-shape = #'upright
-    }
-  }
-}
-@end lilypond
-
-
-@node Output property
-@section Output property
-
-@lilypond[fragment,relative,verbatim]
-    \outputproperty #(make-type-checker 'note-head-interface) 
-      #'extra-offset = #'(2 . 3)
-    c''2 c
-@end lilypond
-
-Don't move the finger 2, only text "m.d." ...
-@lilypond[verbatim]
-#(define (make-text-checker text)
-   (lambda (grob) (equal? text (ly-get-elt-property grob 'text))))
-
-\score {    
-  \notes\relative c''' {
-    \property Voice.Stem \set #'direction = #1
-    \outputproperty #(make-text-checker "m.d.")
-      #'extra-offset = #'(-3.5 . -4.5)
-    a^2^"m.d."    
-  }
-  \paper { linewidth = -1.; }
-}
-@end lilypond
-
-
-@c  equalizer
-
-
-@node Apply hacking
-@section Apply hacking
-
-@lilypond[verbatim]
-music = \notes { c'4 d'4( e'4 f'4 }
-
-#(define (reverse-music music)
-  (let* ((elements (ly-get-mus-property music 'elements))
-        (reversed (reverse elements))
-        (span-dir (ly-get-mus-property music 'span-direction)))
-    
-    (ly-set-mus-property music 'elements reversed)
-    
-    (if (dir? span-dir)
-       (ly-set-mus-property music 'span-direction (- span-dir)))
-    
-    (map reverse-music reversed)
-    
-    music))
-
-\score {
-  \context Voice {
-    \music
-    \apply #reverse-music \music
-  }
-  \paper { linewidth = -1.; }
-}
-@end lilypond
-
-
-LilyPond is more flexible than some users realise.  Han-Wen could be
-very rich.
-
-Just too funny not to include.
-
-@example
-@quotation
-    I've just entered a request on cosource.com :
-@quotation
-        http://www.cosource.com/cgi-bin/cos.pl/wish/info/387
-@end quotation
-    Here's a copy of my feature request :
-@quotation
-        Your task, if you accept it is to implement a \smarttranspose
-        command> that would translate such oddities into more natural
-        notations. Double accidentals should be removed, as well as #E
-        (-> F), bC (-> B), bF (-> E), #B (-> C).
-@end quotation
-@end quotation
-You mean like this. (Sorry 'bout the nuked indentation.)
-
-Add IMPLEMENT_TYPE_P(Music, "music?"); to music.cc, and presto, done.
-
-That's an easy $ 100; if I'd make $ 200/hour for every hour I worked
-on Lily, I'd be very rich :)
-@end example
-
-
-@lilypond[verbatim]
-#(define  (unhair-pitch p)
-  (let* ((o (pitch-octave p))
-         (a (pitch-alteration p))
-        (n (pitch-notename p)))
-
-    (cond
-     ((and (> a 0) (or (eq? n 6) (eq? n 2)))
-      (set! a (- a 1)) (set! n (+ n 1)))
-     ((and (< a 0) (or (eq? n 0) (eq? n 3)))
-      (set! a (+ a 1)) (set! n (- n 1))))
-    
-    (cond
-     ((eq? a 2)  (set! a 0) (set! n (+ n 1)))
-     ((eq? a -2) (set! a 0) (set! n (- n 1))))
-
-    (if (< n 0) (begin (set!  o (- o 1)) (set! n (+ n 7))))
-    (if (> n 7) (begin (set!  o (+ o 1)) (set! n (- n 7))))
-    
-    (make-pitch o n a)))
-
-#(define (smart-transpose music pitch)
-  (let* ((es (ly-get-mus-property music 'elements))
-        (e (ly-get-mus-property music 'element))
-        (p (ly-get-mus-property music 'pitch))
-        (body (ly-get-mus-property music 'body))
-        (alts (ly-get-mus-property music 'alternatives)))
-
-    (if (pair? es)
-       (ly-set-mus-property
-        music 'elements
-        (map (lambda (x) (smart-transpose x pitch)) es)))
-    
-    (if (music? alts)
-       (ly-set-mus-property
-        music 'alternatives
-        (smart-transpose alts pitch)))
-    
-    (if (music? body)
-       (ly-set-mus-property
-        music 'body
-        (smart-transpose body pitch)))
-
-    (if (music? e)
-       (ly-set-mus-property
-        music 'element
-        (smart-transpose e pitch)))
-    
-    (if (pitch? p)
-       (begin
-         (set! p (unhair-pitch (Pitch::transpose p pitch)))
-         (ly-set-mus-property music 'pitch p)))
-    
-    music))
-
-    
-music = \notes \relative c' { c4 d  e f g a b  c }
-
-\score {
-  \notes \context Staff {
-    \transpose ais' \music
-    \apply #(lambda (x) (smart-transpose x (make-pitch 0 5 1)))
-      \music
-  }
-  \paper { linewidth = -1.; }
-}
-@end lilypond
-
-
-@node Embedded TeX
-@section Embedded TeX
-@lilypond[fragment,relative,verbatim]
-  a''^"3 $\\times$ \\`a deux"
-@end lilypond
-
-@node Embedded PostScript
-@section Embedded PostScript
-
-Arbitrary lines and curves not supported...
-
-[TODO:] Make a direct postscript command?
-
-@lilypond[verbatim]
-\score {
-  \notes \relative c'' {
-    a-#"\\embeddedps{3 4 moveto 5 3 rlineto stroke}"
-    -#"\\embeddedps{ [ 0 1 ] 0 setdash 3 5 moveto 5 -3 rlineto stroke}"
-    b-#"\\embeddedps{3 4 moveto 0 0 1 2 8 4 20 3.5 rcurveto stroke}"
-    s2
-    a'1
-  }
-  \paper { linewidth = 70 * \staffspace; }
-}
-@end lilypond
-
-
-@node Index
-@section Checking Feature index
-
-@printindex cp
-
-
-@bye
-
-
-
index 412acc343d7fa6262e7b6b09b63cb1f764096156..c6c63bd78bcb5e46fa17540aff8313b8e384cade 100644 (file)
@@ -87,6 +87,7 @@ than the names being similar :-)"
 
 @ifnottex
 @node Top
+@c FIXME: this should not be necessary...
 @top
 @end ifnottex
 
@@ -104,13 +105,13 @@ this and other documentation.
 
 
 @menu
-* Tutorial::                       A tutorial introduction to lilypond.
+* Tutorial::                       A tutorial introduction to LilyPond.
 * Invoking LilyPond::              Operation.
 * Bug reports::                   Where to report bugs.
 * Reference Manual::               Reference Manual.
-@c Move to Reference Manual?
+* Features::                       Features, tips and tricks.
 * Internals:(lilypond-internals).  Auto generated detailed documentation.
-* convert-ly::                     Upgrading input files.
+* Programs::                       External programs.
 * Internals::                      How it all works.
 * Development::                    On developing code for LilyPond.
 * Index::                          Unified index.
@@ -118,16 +119,8 @@ this and other documentation.
 
 @contents
 
-@macro keyindex {word}
-@cindex @code{ \word\ }
-
-@end macro
-
-@macro indexcode {word}
-@cindex @code{ \word\ }
-
-@end macro
 
+@mbinclude macros.itexi
 
 @mbinclude tutorial.itely
 
@@ -137,10 +130,13 @@ this and other documentation.
 
 @mbinclude refman.itely
 
-@mbinclude convert-ly.itexi
+@mbinclude features.itely
+
+@mbinclude programs.itexi
 
 @mbinclude development.itexi
 
+@c FIXME: Index has two alphabetically sorted lists @code vs plain?
 @node Index
 @unnumbered Index
 
diff --git a/Documentation/user/ly2dvi.itexi b/Documentation/user/ly2dvi.itexi
new file mode 100644 (file)
index 0000000..345d048
--- /dev/null
@@ -0,0 +1,253 @@
+@c -*-texinfo-*-
+
+@node Ly2dvi
+@section Ly2dvi
+
+Ly2dvi is a Python script which creates input file for La@TeX{},
+based on information from the output files from LilyPond.
+The script handles multiple files. If a LilyPond file name is
+specified LilyPond is run to make an output (@TeX{}) file.
+
+One or more La@TeX{} files are created, based on information found
+in the output (@TeX{}) files, and latex is finally run to create
+one or more DVI files.
+
+The majority of this utility came from a bourne script written by Jan
+Arne Fagertun name @file{ly2dvi}. 
+
+@subsection Invoking ly2dvi
+
+        ly2dvi [options] inputfile[.ly] [....]
+
+
+@table @samp
+@item -D,--debug
+    Set debug mode. There are two levels - in level one some debug
+    info is written, in level two the command @strong{set -x} is run, which
+    echoes every command in the ly2dvi script.
+@item -F,--headers=
+    Name of additional La@TeX{} headers file. This is included in the
+    tex file at the end of the headers, last line before @code{\begin@{document@}}
+@item -H,--Heigth=
+    Set paper heigth (points). Used together with width and La@TeX{} name of
+    papersize in case of papersize unknown to ly2dvi.
+@item -K,--keeplilypond
+    Keep LilyPond output after the run.
+@item -L,--landscape
+    Set landscape orientation - portrait is the default.
+    Use together with @code{dvips -t landscape} if you run dvips 
+    separately. 
+@item -N,--nonumber
+    Switch off page numbering.
+@item -O,--orientation=
+    Set orientation landscape - obsolete, use @strong{-L} instead.
+@item -P,--postscript
+    In addition to the DVI file, also Generate a postsript file.
+@item -W,--Width=
+    Set paper width (points). Used together with heigth and La@TeX{} name of
+    papersize in case of papersize unknown to ly2dvi.
+@item -d,--dependencies
+    Tell LilyPond to make dependencies file.
+@item -h,--help
+    Print help.
+@item -k,--keeply2dvi
+    Keep the La@TeX{} file after the run.
+@item -l,--language=
+    Specify La@TeX{} language.
+    (@strong{-l norsk} produces @code{\usepackage[norsk]@{babel@}}).
+@item -o,--output=
+    Set output directory.
+@item -p,--papersize=
+    Specify papersize.
+    (@strong{-p a4} produces @code{\usepackage[a4paper]@{article@}})
+@item -s,--separate
+    Normally all output files are included into one La@TeX{} file.
+    With this switch all files are run separately, to produce one
+    DVI file for each.
+@end table
+
+
+@subsection Ly2dvi Features
+
+Ly2dvi responds to several parameters specified in the LilyPond
+file. They are overridden by corresponding command line options.
+
+@table @samp
+@item language="";
+    Specify La@TeX{} language
+@item latexheaders="";
+    Specify additional La@TeX{} headers file
+@item orientation="";
+    Set orientation.
+@item paperlinewidth="";
+    Specify the width (pt, mm or cm) of the printed lines.
+@item papersize="";
+    Specify name of papersize.
+@end table
+
+@subsection Ly2dvi Environment
+
+@table @samp
+@item LILYPONDPREFIX
+    Sets the root directory of the LilyPond installation
+@item LILYINCLUDE
+    Additional directories for input files.
+@item TMP
+    Temporary directory name. Default is /tmp
+@end table
+
+@subsection Ly2dvi Files
+
+@file{titledefs.tex} is inspected for definitions used to extract
+additional text definitions from the LilyPond file. In the current
+version the following are defined:
+
+@table @samp
+@item title
+    The title of the music. Centered on top of the first page.
+@item subtitle
+    Subtitle, centered below the title.
+@item poet
+    Name of the poet, leftflushed below the below subtitle.
+@item composer
+    Name of the composer, rightflushed below the subtitle.
+@item metre
+    Meter string, leftflushed below the below poet.
+@item opus
+    Name of the opus, rightflushed below the below composer.
+@item arranger
+    Name of the arranger, rightflushed below the opus.
+@item instrument
+    Name of the instrument, centered below the arranger
+@item piece
+    Name of the piece, leftflushed below the instrument
+@end table
+
+@file{$LILYPONDPREFIX/share/.lilyrc $HOME/.lilyrc ./.lilyrc} are files
+to set up default running conditions.  On Windows OS initialization
+files are named @file{_lilyrc}. The file syntax is as follows:
+
+@example 
+VARIABLE-NAME=VALUE 
+@end example 
+
+Where @strong{VARIABLE-NAME} is the name of the variable documented below
+and @strong{VALUE} is either a string, a 1, or a 0.  All files are parsed,
+in the shown sequence. In the current version the following are
+allowed:
+
+@table @samp
+@item DEBUG=value
+This turns off (default) or on the debug capabilities.  Possible
+values are 0 (off) and 1 (on).
+@item DEPENDENCIES=value
+This turns off (default) or on the ability to generate a Makefile
+dependency list.  Possible values are 0 (off) and 1 (on).
+@item KEEPLILYPOND=value
+This turns off (default) or on the ability to keep the log file
+associated with the LilyPond job.  Possible values are 0 (off) and 1
+(on).
+@item KEEPLY2DVI=value
+This turns off (default) or on the ability to keep the temporary files
+that are generated by the ly2dvi job.  Possible values are 0 (off) and
+1 (on)
+@item LANGUAGE=value
+Specify La@TeX{} language.  Possible value is a valid La@TeX{} language.
+@item LATEXHF=value
+Specify additional La@TeX{} headers file.  Possible value is a file
+specification. 
+@item LILYINCLUDE=value
+Additional directories for input files.  Possible value is a delimited
+directory path list.
+@item LILYPONDPREFIX=value
+This defines the LilyPond root directory.  Possible value is a valid
+directory specification to the LilyPond distribution location.
+@item NONUMBER=value
+This turns off (default) or on the page numbering capability.
+Possible values are 0 (page numbering enabled) and 1 (page numbering
+disabled). 
+@item ORIENTATION=value
+This sets the image orientation.  Possible values are
+portrait (default) and landscape.
+@item OUTPUTDIR=value
+This defines the directory where the resultant files will be
+generated.  Possible value is a valid directory specification.
+Default is the current working directory.
+@item PAPERSIZE=value
+This defines the papersize the image will be sized to fit.  Possible
+values are a0, a1, a2, a3, a4 (default), a5, a6, a7, a8, a9, a10, b0,
+b1, b2, b3, b4, b5, archA, archB, archC, archD, archE, flsa, flse,
+halfletter, ledger, legal, letter, or note.
+@item PHEIGHT=value
+Specify paperheight (points - an inch is 72.27, a cm is 28.453 points).
+@item POSTSCRIPT=value
+This turns off (default) or on the capability of additionally
+generating a postscript file.  Possible values are 0 (off) and 1 (on).
+@item PWIDTH=value
+Specify paperwidth (points - an inch is 72.27, a cm is 28.453 points).
+@item SEPARATE=value
+This turns off (default) or on the capability of generating multiple
+dvi and postscript files from multiple source files.  The default is
+to generate a concatenation of the source files.  Possible values are
+0 (single file) and 1 (separate files).
+@item TMP=value
+This defines the emporary directory.  Actually this is not used at the
+present.  Possible value is a valid directory specification that is
+writable to the user.
+@end table
+
+@subsection Ly2dvi Initialization Sequence
+The initialization process reads inputs for several sources.  Below is
+a list of priorities for lowest to hightest proirity.
+
+@itemize @bullet
+@item  Program's defaults
+@item  Values found in LilyPond output file
+@item  Environment variables
+@item  $LILYPONDPREFIX/share/lilypond/.lilyrc
+@item  $HOME/.lilyrc
+@item  ./.lilyrc
+@item  command line options
+@end itemize
+
+Note that this differs slightly from the original bourne shell
+version. 
+
+@subsection Ly2dvi Bugs
+
+@c should?
+FIXME.
+See @ref{Bug reports}.
+If you have found a bug, you should send a bugreport.
+
+@itemize @bullet
+@item Send a copy of the input which causes the error.
+@item Send a description of the platform you use.
+@item Send a description of the LilyPond and ly2dvi version you use.
+@item Send a description of the bug itself.
+@item Send it to @email{bug-gnu-music@@gnu.org} (you don't have to subscribe
+    to this mailinglist).
+@end itemize
+
+@subsection Ly2dvi Remarks
+
+Many papersizes are now supported. Information on other sizes
+(La@TeX{} names, horizontal and vertical sizes) should be mailed to
+the author or to the mailing list.
+
+Supported papersizes are:
+
+a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, archA, archB, archC, archD,
+archE, b0, b1, b2, b3, b4, b5, flsa, flse, halfletter, ledger, legal,
+letter, note
+
+@subsection Ly2dvi Authors
+Python Version author:
+@email{daboys@@austin.rr.com, Jeffrey B. Reed},
+@uref{http://home.austin.rr.com/jbr/jeff/lilypond/}
+
+Original bourne shell version author:
+@email{Jan.A.Fagertun@@energy.sintef.no, Jan Arne Fagertun},
+@uref{http://www.termo.unit.no/mtf/people/janaf/}
+
index 959802de658815ffa658f4f313bc220e8cf647d4..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 100644 (file)
@@ -1,258 +0,0 @@
-\input texinfo @c -*-texinfo-*-
-@setfilename ly2dvi.info
-@settitle ly2dvi
-
-@chapter Ly2dvi
-
-@section DESCRIPTION
-ly2dvi is a Python script which creates input file for La@TeX{},
-based on information from the output files from LilyPond.
-The script handles multiple files. If a lilypond file name is
-specified LilyPond is run to make an output (@TeX{}) file.
-
-One or more La@TeX{} files are created, based on information found
-in the output (@TeX{}) files, and latex is finally run to create
-one or more DVI files.
-
-The majority of this utility came from a bourne script written by Jan
-Arne Fagertun name @file{ly2dvi}. 
-
-@section SYNOPSIS
-
-        ly2dvi [options] inputfile[.ly] [....]
-
-
-@section OPTIONS
-
-@table @samp
-@item -D,--debug
-    Set debug mode. There are two levels - in level one some debug
-    info is written, in level two the command @strong{set -x} is run, which
-    echoes every command in the ly2dvi script.
-@item -F,--headers=
-    Name of additional La@TeX{} headers file. This is included in the
-    tex file at the end of the headers, last line before @code{\begin@{document@}}
-@item -H,--Heigth=
-    Set paper heigth (points). Used together with width and La@TeX{} name of
-    papersize in case of papersize unknown to ly2dvi.
-@item -K,--keeplilypond
-    Keep LilyPond output after the run.
-@item -L,--landscape
-    Set landscape orientation - portrait is the default.
-    Use together with @code{dvips -t landscape} if you run dvips 
-    separately. 
-@item -N,--nonumber
-    Switch off page numbering.
-@item -O,--orientation=
-    Set orientation landscape - obsolete, use @strong{-L} instead.
-@item -P,--postscript
-    In addition to the DVI file, also Generate a postsript file.
-@item -W,--Width=
-    Set paper width (points). Used together with heigth and La@TeX{} name of
-    papersize in case of papersize unknown to ly2dvi.
-@item -d,--dependencies
-    Tell lilypond to make dependencies file.
-@item -h,--help
-    Print help.
-@item -k,--keeply2dvi
-    Keep the La@TeX{} file after the run.
-@item -l,--language=
-    Specify La@TeX{} language.
-    (@strong{-l norsk} produces @code{\usepackage[norsk]@{babel@}}).
-@item -o,--output=
-    Set output directory.
-@item -p,--papersize=
-    Specify papersize.
-    (@strong{-p a4} produces @code{\usepackage[a4paper]@{article@}})
-@item -s,--separate
-    Normally all output files are included into one La@TeX{} file.
-    With this switch all files are run separately, to produce one
-    DVI file for each.
-@end table
-
-
-@section Features
-
-ly2dvi responds to several parameters specified in the lilypond
-file. They are overridden by corresponding command line options.
-
-@table @samp
-@item language="";
-    Specify La@TeX{} language
-@item latexheaders="";
-    Specify additional La@TeX{} headers file
-@item orientation="";
-    Set orientation.
-@item paperlinewidth="";
-    Specify the width (pt, mm or cm) of the printed lines.
-@item papersize="";
-    Specify name of papersize.
-@end table
-
-@section Environment
-
-@table @samp
-@item LILYPONDPREFIX
-    Sets the root directory of the LilyPond installation
-@item LILYINCLUDE
-    Additional directories for input files.
-@item TMP
-    Temporary directory name. Default is /tmp
-@end table
-
-@section Files
-
-@file{titledefs.tex} is inspected for definitions used to extract
-additional text definitions from the lilypond file. In the current
-version the following are defined:
-
-@table @samp
-@item title
-    The title of the music. Centered on top of the first page.
-@item subtitle
-    Subtitle, centered below the title.
-@item poet
-    Name of the poet, leftflushed below the below subtitle.
-@item composer
-    Name of the composer, rightflushed below the subtitle.
-@item metre
-    Meter string, leftflushed below the below poet.
-@item opus
-    Name of the opus, rightflushed below the below composer.
-@item arranger
-    Name of the arranger, rightflushed below the opus.
-@item instrument
-    Name of the instrument, centered below the arranger
-@item piece
-    Name of the piece, leftflushed below the instrument
-@end table
-
-@file{$LILYPONDPREFIX/share/.lilyrc $HOME/.lilyrc ./.lilyrc} are files
-to set up default running conditions.  On Windows OS initialization
-files are named @file{_lilyrc}. The file syntax is as follows:
-
-@example 
-VARIABLE-NAME=VALUE 
-@end example 
-
-Where @strong{VARIABLE-NAME} is the name of the variable documented below
-and @strong{VALUE} is either a string, a 1, or a 0.  All files are parsed,
-in the shown sequence. In the current version the following are
-allowed:
-
-@table @samp
-@item DEBUG=value
-This turns off (default) or on the debug capabilities.  Possible
-values are 0 (off) and 1 (on).
-@item DEPENDENCIES=value
-This turns off (default) or on the ability to generate a Makefile
-dependency list.  Possible values are 0 (off) and 1 (on).
-@item KEEPLILYPOND=value
-This turns off (default) or on the ability to keep the log file
-associated with the LilyPond job.  Possible values are 0 (off) and 1
-(on).
-@item KEEPLY2DVI=value
-This turns off (default) or on the ability to keep the temporary files
-that are generated by the ly2dvi job.  Possible values are 0 (off) and
-1 (on)
-@item LANGUAGE=value
-Specify La@TeX{} language.  Possible value is a valid La@TeX{} language.
-@item LATEXHF=value
-Specify additional La@TeX{} headers file.  Possible value is a file
-specification. 
-@item LILYINCLUDE=value
-Additional directories for input files.  Possible value is a delimited
-directory path list.
-@item LILYPONDPREFIX=value
-This defines the LilyPond root directory.  Possible value is a valid
-directory specification to the LilyPond distribution location.
-@item NONUMBER=value
-This turns off (default) or on the page numbering capability.
-Possible values are 0 (page numbering enabled) and 1 (page numbering
-disabled). 
-@item ORIENTATION=value
-This sets the image orientation.  Possible values are
-portrait (default) and landscape.
-@item OUTPUTDIR=value
-This defines the directory where the resultant files will be
-generated.  Possible value is a valid directory specification.
-Default is the current working directory.
-@item PAPERSIZE=value
-This defines the papersize the image will be sized to fit.  Possible
-values are a0, a1, a2, a3, a4 (default), a5, a6, a7, a8, a9, a10, b0,
-b1, b2, b3, b4, b5, archA, archB, archC, archD, archE, flsa, flse,
-halfletter, ledger, legal, letter, or note.
-@item PHEIGHT=value
-Specify paperheight (points - an inch is 72.27, a cm is 28.453 points).
-@item POSTSCRIPT=value
-This turns off (default) or on the capability of additionally
-generating a postscript file.  Possible values are 0 (off) and 1 (on).
-@item PWIDTH=value
-Specify paperwidth (points - an inch is 72.27, a cm is 28.453 points).
-@item SEPARATE=value
-This turns off (default) or on the capability of generating multiple
-dvi and postscript files from multiple source files.  The default is
-to generate a concatenation of the source files.  Possible values are
-0 (single file) and 1 (separate files).
-@item TMP=value
-This defines the emporary directory.  Actually this is not used at the
-present.  Possible value is a valid directory specification that is
-writable to the user.
-@end table
-
-@section Initialization Sequence
-The initialization process reads inputs for several sources.  Below is
-a list of priorities for lowest to hightest proirity.
-
-@itemize @bullet
-@item  Program's defaults
-@item  Values found in LilyPond output file
-@item  Environment variables
-@item  $LILYPONDPREFIX/share/lilypond/.lilyrc
-@item  $HOME/.lilyrc
-@item  ./.lilyrc
-@item  command line options
-@end itemize
-
-Note that this differs slightly from the original bourne shell
-version. 
-
-@section See Also
-
-lilypond(1), tex(1), latex(1)
-
-@section Bugs
-
-If you have found a bug, you should send a bugreport.
-
-@itemize @bullet
-@item Send a copy of the input which causes the error.
-@item Send a description of the platform you use.
-@item Send a description of the LilyPond and ly2dvi version you use.
-@item Send a description of the bug itself.
-@item Send it to @email{bug-gnu-music@@gnu.org} (you don't have to subscribe
-    to this mailinglist).
-@end itemize
-
-@section Remarks
-
-Many papersizes are now supported. Information on other sizes
-(La@TeX{} names, horizontal and vertical sizes) should be mailed to
-the author or to the mailing list.
-
-Supported papersizes are:
-
-a0, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, archA, archB, archC, archD,
-archE, b0, b1, b2, b3, b4, b5, flsa, flse, halfletter, ledger, legal,
-letter, note
-
-@section Authors
-Python Version author:
-@email{daboys@@austin.rr.com, Jeffrey B. Reed},
-@uref{http://home.austin.rr.com/jbr/jeff/lilypond/}
-
-Original bourne shell version author:
-@email{Jan.A.Fagertun@@energy.sintef.no, Jan Arne Fagertun},
-@uref{http://www.termo.unit.no/mtf/people/janaf/}
-
diff --git a/Documentation/user/macros.itexi b/Documentation/user/macros.itexi
new file mode 100644 (file)
index 0000000..b7dff0a
--- /dev/null
@@ -0,0 +1,44 @@
+
+@ifnottex
+@macro keyindex {word}
+@cindex @code{ \word\ }
+@end macro
+
+@macro indexcode {word}
+@cindex @code{ \word\ }
+@end macro
+@end ifnottex
+
+@iftex
+@macro keyindex {word}
+@cindex @code{ \word\ }
+
+@end macro
+
+@macro indexcode {word}
+@cindex @code{ \word\ }
+
+@end macro
+@end iftex
+
+@ifinfo
+@macro rgrob {word}
+@ref{ (lilypond-internals)Grob \word\, \word\ },
+
+@end macro
+@macro reng {word}
+@ref{ (lilypond-internals)Engraver \word\, \word\ },
+
+@end macro
+@end ifinfo
+
+@ifnotinfo
+@macro rgrob {word}
+@ref{ (lilypond-internals)Grob \word\, \word\ }
+
+@end macro
+@macro reng {word}
+@ref{ (lilypond-internals)Engraver \word\, \word\ }
+
+@end macro
+@end ifnotinfo
diff --git a/Documentation/user/midi2ly.itexi b/Documentation/user/midi2ly.itexi
new file mode 100644 (file)
index 0000000..3ba2985
--- /dev/null
@@ -0,0 +1,42 @@
+@c -*-texinfo-*-
+
+@node Midi2ly
+@section Midi2ly
+
+Midi2ly translates a MIDI input file to a LilyPond source file.
+Midi2ly is part of the GNU LilyPond music typesetting package.
+
+@subsection Invoking midi2ly
+
+       midi2ly [options] midi-file
+
+
+@table @samp
+@item -b, --no-quantify,
+    Write exact durations, e.g.: `a4*385/384'.
+@item -D, --debug,
+    Print lots of debugging stuff.
+@item -h, --help,
+    Show a summary of usage.
+@item -I, --include=@file{DIR},
+    Add DIR to search path.
+@item -k, --key=ACC[:MINOR],
+    Set default key.  ACC > 0 sets number of sharps; ACC < 0 sets number 
+    of flats.  A minor key is indicated by ":1".
+@item -n, --no-silly,
+    Assume no plets or double dots, assume smallest (reciprocal) duration 16.
+@item -o, --output=@file{FILE},
+    Set @file{FILE} as default output.
+@item -p, --no-plets,
+    Assume no plets.
+@item -q, --quiet,
+    Be quiet.
+@item -s, --smallest=N,
+    Assume no shorter (reciprocal) durations than N.
+@item -v, --verbose,
+    Be verbose.
+@item -w, --warranty,
+    Show the warranty with which midi2ly comes. (It comes with @strong{NO WARRANTY}!)
+@item -x, --no-double-dots,
+    Assume no double dotted notes.
+@end table
index 7a4609d43691f28f1fea22dc328509e78e49ddb1..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 100644 (file)
@@ -1,46 +0,0 @@
-\input texinfo @c -*-texinfo-*-
-@setfilename midi2ly.info
-@settitle midi2ly
-
-
-@chapter midi2ly
-
-@section DESCRIPTION
-midi2ly translates a MIDI input file to Mudela (GNU LilyPond source
-format).  midi2ly is part of the GNU LilyPond music typesetting package.
-
-       midi2ly [options] midi-file
-
-@section OPTIONS
-
-@table @samp
-@item -b, --no-quantify,
-    Write exact durations, e.g.: `a4*385/384'.
-@item -D, --debug,
-    Print lots of debugging stuff.
-@item -h, --help,
-    Show a summary of usage.
-@item -I, --include=@file{DIR},
-    Add DIR to search path.
-@item -k, --key=ACC[:MINOR],
-    Set default key.  ACC > 0 sets number of sharps; ACC < 0 sets number 
-    of flats.  A minor key is indicated by ":1".
-@item -n, --no-silly,
-    Assume no plets or double dots, assume smallest (reciprocal) duration 16.
-@item -o, --output=@file{FILE},
-    Set @file{FILE} as default output.
-@item -p, --no-plets,
-    Assume no plets.
-@item -q, --quiet,
-    Be quiet.
-@item -s, --smallest=N,
-    Assume no shorter (reciprocal) durations than N.
-@item -v, --verbose,
-    Be verbose.
-@item -w, --warranty,
-    Show the warranty with which midi2ly comes. (It comes with @strong{NO WARRANTY}!)
-@item -x, --no-double-dots,
-    Assume no double dotted notes.
-@end table
-
-@bye
diff --git a/Documentation/user/programs.itexi b/Documentation/user/programs.itexi
new file mode 100644 (file)
index 0000000..6bd147a
--- /dev/null
@@ -0,0 +1,16 @@
+@c -*-texinfo-*-
+
+@node Programs
+@chapter Programs
+
+@menu
+* Ly2dvi::                         Generating nice output with titles.
+* Convert-ly::                     Upgrading input files.
+* Midi2ly::                        Converting from MIDI input.
+@end menu
+
+@mbinclude ly2dvi.itexi
+@mbinclude convert-ly.itexi
+@mbinclude midi2ly.itexi
+
+
index 94252fb529f580e353a011cf227f7bae906d58a6..518da2666e5ce98393237d96f6bc084c3a232e70 100644 (file)
@@ -5,8 +5,13 @@
 @c - Restructure! Separate internal commands from user level commands. /MB
 @c - Add some words about Guile.  /MB
 @c - Fix indexing (keyindex) so it doesn't add line breaks  /MB
+@c
+@c FIXME: Index has two alphabetically sorted lists @code vs plain?
+@c 
+@c If we'd include the auto-generated documentation, we 'd get a lot of
+@c very useful index entries.
+@c 
 
-@c ugh: because of @include, we need to fill in these nodes
 
 @node Reference Manual
 @chapter Reference Manual
@@ -41,7 +46,6 @@
 * Sound output::                   Sound output
 * midilist::                       midilist
 * Pre-defined Identifiers::        Pre-defined Identifiers
-@c May be fragile.  Better make single link to generated doco?
 * Interpretation contexts:(lilypond-internals)LilyPond interpretation contexts.
 * Engravers:(lilypond-internals)LilyPond engravers.
 * Backend:(lilypond-internals)LilyPond backend.
@@ -119,7 +123,7 @@ It is customary to put the @code{\header} at the top of the file.
 Note names and chord modifiers can be customised for nationalities.
 languages and conventions.  The syntax is as follows.
 @example
-   \pitchnames @keyindex{pitchnames} @var{scheme-alist}
+   \pitchnames@keyindex{pitchnames} @var{scheme-alist}
    \chordmodifiers@keyindex{chordmodifiers} @var{scheme-alist}
 @end example
 
@@ -1901,17 +1905,20 @@ display the chord name after a line break:
 @quotation
 @lilypond[verbatim]
 scheme = \chords {
-%  \property ChordNames.chordChanges = ##t
   c1:m \break c:m c:m c:m d
 }
 
 \score {
   \notes <
-    \context ChordNamesVoice \scheme
+    \context ChordNames \scheme
     \context Staff \transpose c'' \scheme
   >
   \paper{
     linewidth = 40 * \staffspace;
+    \translator {
+      \ChordNamesContext
+      chordChanges = ##t
+    }
   }
 }
 @end lilypond
index 6b6a0606f644cc93b8099bf7c7fb073c1ce73a62..d6b12347593045cd0542731ea6de9de29646b8c3 100644 (file)
@@ -1,6 +1,5 @@
 @c -*-texinfo-*-
 
-@c ugh: because of @include, we need to fill in these nodes?
 @node Tutorial
 @chapter Tutorial
 
diff --git a/VERSION b/VERSION
index 08224c987200d7985990ae7bc54de9222410245d..293a139c39e1be8e35f43ba4ff1f3939acd49eaa 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -2,7 +2,7 @@ PACKAGE_NAME=LilyPond
 MAJOR_VERSION=1
 MINOR_VERSION=3
 PATCH_LEVEL=122
-MY_PATCH_LEVEL=jcn1
+MY_PATCH_LEVEL=jcn2
 
 # use the above to send patches: MY_PATCH_LEVEL is always empty for a
 # released version.
index 55f2d1d1f081b02057da680378f6a8bece5e47c2..49e8c4cc146cd3d84a3cfc693d45b279a374fae1 100644 (file)
@@ -6,16 +6,24 @@ chord name after a line break.
 }
 
 scheme = \chords {
-  \property ChordNames.chordChanges = ##t
+ % ugh ugh: this breaks the output of notes in the regular staff 
+ \property ChordNamesVoice.chordChanges = ##t
+  % and this even breaks the chord names 
+   \property ChordNames.chordChanges = ##t
+  c1:m \break c:m c:m c:m d
   c1:m \break c:m c:m c:m d
 }
 
 \score {
   \notes <
-    \context ChordNamesVoice \scheme
+    \context ChordNames \scheme
     \context Staff \transpose c'' \scheme
   >
   \paper{
     linewidth = 40 * \staffspace;
+    \translator {
+      \ChordNamesVoiceContext
+      chordChanges = ##t
+    }
   }
 }
index 2ac2cc20e9dd143038fe70620308f8cf954f137d..f9a7697319d0a562de85ca1e10822ebc01c341c9 100644 (file)
@@ -6,16 +6,21 @@ chord name after a line break.
 }
 
 scheme = \chords {
-%  \property ChordNames.chordChanges = ##t
+ % ugh ugh: this breaks the output of notes in the regular staff 
+%  \property ChordNamesVoice.chordChanges = ##t
   c1:m \break c:m c:m c:m d
 }
 
 \score {
   \notes <
-    \context ChordNamesVoice \scheme
+    \context ChordNames \scheme
     \context Staff \transpose c'' \scheme
   >
   \paper{
     linewidth = 40 * \staffspace;
+    \translator {
+      \ChordNamesContext
+      chordChanges = ##t
+    }
   }
 }
index a3541404a3c049e7a2cf2290b969fa83f6ac4344..ebe406f1f849d7533acc49c46b3c619c5d8aacf1 100644 (file)
@@ -35,6 +35,7 @@ private:
   void add_note (Note_req *);
   
   Item* chord_name_p_;
+
   Protected_scm chord_;
   Protected_scm last_chord_;
 };
@@ -93,18 +94,8 @@ Chord_name_engraver::create_grobs ()
       chord_name_p_->set_grob_property ("chord", chord_);
       announce_grob (chord_name_p_, 0);
       SCM s = get_property ("chordChanges");
-#ifdef DEBUG
-      /*
-       gdb crashes upon printscm (chord_) etc...
-       ugh: why does gh_equal_p () not seem to work??
-       */
-      printf ("chord: %s\n",  ly_scm2string (ly_write2scm (chord_)).ch_C ());
-      printf ("last_chord: %s\n", ly_scm2string (ly_write2scm (last_chord_)).ch_C ());
-      int i = gh_equal_p (chord_, last_chord_);
-      printf ("i: %d\n", i);
-#endif
       if (to_boolean (s) && last_chord_ != SCM_EOL
-         && gh_equal_p (chord_, last_chord_))
+                 && gh_equal_p (chord_, last_chord_))
        chord_name_p_->set_grob_property ("begin-of-line-visible", SCM_BOOL_T);
     }
 }
index a4e428e5d4ffc75c381fb130a4cac4e15c6ff1b0..2b7fa42d67adbf552b653e95ef130fb8a43595e4 100644 (file)
@@ -152,6 +152,8 @@ Chord::member_notename (SCM p, SCM pitches)
            }
        }
     }
+  else
+    member = gh_car (member);
   return member;
 }
 
@@ -175,6 +177,8 @@ Chord::member_pitch (SCM p, SCM pitches)
            }
        }
     }
+  else
+    member = gh_car (member);
   return member;
 }
 
index 902f8c507fb5c394071a38a5b2a71467054ae71a..c38d5458293d5f26b3d7eca2d622f23e0b3701c7 100644 (file)
@@ -51,7 +51,8 @@ void                                                          \
 CL::init_smobs ()                                              \
 {                                                              \
   smob_tag_ = scm_make_smob_type_mfpe (                                \
-     #CL, 0, CL::mark_smob, CL::free_smob, CL::print_smob, 0); \
+     #CL, 0, CL::mark_smob, CL::free_smob, CL::print_smob,     \
+     CL::equal_p);                                              \
 }                                                              \
 SCM CL::smobbed_self () const                                  \
 {                                                              \
index d33d70bca3582f655a438cac6ed1c05069ff4f24..ac1e63a75cc4027cefb118965bf6372e6a2a1c76 100644 (file)
 
 
 (define (backend-property->texi sym)
-  (let* (
-       (name (symbol->string sym))
+  (let* ((name (symbol->string sym))
        (type (object-property sym 'backend-type?))
        (typename (type-name type))
-       (desc (object-property sym 'backend-doc))
-       )
+       (desc (object-property sym 'backend-doc)))
 
     (cons (string-append "@code{" name "} "
                       "(" typename ")"
                       ":" )
-         desc)
-    ))
+         desc)))
 
 (define (document-grob-property sym grob-description only-doc-if-set)
-  (let*
-      (
-       (handle (assoc sym grob-description))
-       (defval (if (eq? handle #f)
-                  ""
-                  (scm->texi (cdr handle))
-                  ))
-       (propdoc (backend-property->texi sym))
-       )
-
-    (if (and only-doc-if-set  (eq? handle #f) )
+  (let* ((handle (assoc sym grob-description))
+        (defval (if (eq? handle #f)
+                    ""
+                  (scm->texi (cdr handle))))
+        (propdoc (backend-property->texi sym)))
+        
+    (if (and only-doc-if-set  (eq? handle #f))
        '("" . "")
        (cons (car propdoc) (string-append (cdr propdoc)
                                           "\nDefault value: "
-                                          defval)))
-    ))
+                                          defval)))))
 
 (define (document-interface where interface grob-description)
-  "
-
-"
   (let* ((level (if (eq? where 'grob) 3 2))
         (name (car interface))
         (desc (cadr interface))
         (props (caddr interface))
-        (docfunc  (lambda (x)
+        (docfunc (lambda (x)
                    (document-grob-property
                     x grob-description (eq? where 'grob))))
-        (docs (map docfunc props))
-        )
+        (docs (map docfunc props)))
 
     (string-append
-     (texi-section level (string-append (interface-name (symbol->string name))) (eq? where 'grob)) ;gur.
+     (texi-section level
+                  (string-append (interface-name (symbol->string name)))
+                  (eq? where 'grob)) ;gur.
      desc
-     
-     (description-list->texi docs)
-     )))
+     (description-list->texi docs))))
 
 ;; First level Interface description
 (define (document-separate-interface interface)
-  (let ((name (car interface)))
+  (let ((name (symbol->string (car interface))))
     (processing name)
     (string-append
      (node (interface-name name))
         
         (name (cdr (assoc 'name meta)))
         (ifaces (cdr (assoc 'interface-descriptions meta)))
-        (ifacedoc (map (lambda (x) (document-interface 'grob x description))
+        (ifacedoc (map (lambda (x)
+                         (document-interface 'grob x description))
                        (reverse ifaces))))
-    
+
     (string-append
      (node (grob-name name))
      (texi-section 2 (grob-name name) #f)
                         engraver-description-alist))))
        (string-append
        name " grobs are created by: "
-       (human-listify (map reffy (map engraver-name engravers)))))
+       (human-listify (map reffy
+                           (map engraver-name
+                                (map symbol->string engravers))))))
 
      (apply string-append ifacedoc))))
      
 
 (define (document-all-grobs name)
   (let* ((doc (apply string-append
-                    (map (lambda (x) (document-grob (car x) (cdr x)))
+                    (map (lambda (x)
+                           (document-grob (symbol->string (car x)) (cdr x)))
                          all-grob-descriptions)))
-        (names (map car all-grob-descriptions)))
+        (names (map symbol->string (map car all-grob-descriptions))))
 
     (string-append
      (texi-node-menu name (map (lambda (x) (cons (grob-name x) ""))
 (define (ugh-standalone-list-interface-names)
   (let* ((text interface-file-str)
         (t1 (regexp-substitute/global #f "\n" text 'pre 'post))
-        (t (regexp-substitute/global #f "[^\t ]*[ \t]([a-z-]+interface)" 
+        (t (regexp-substitute/global #f "[^\t ]define[ \t]*([a-z-]+interface)" 
                                      t1 1 " " 'post))
         (ugh (regexp-substitute/global #f "  .*" t 'pre 'post))
         (l (separate-fields-discarding-char #\  ugh list)))
 ;; guile> (load "backend-documentation-lib.scm")
 ;; For some reason, this can't be generated when lilypond is loaded;
 ;; the regexp stuff behaves weird.
-(define (list-interface-names) '("general-grob-interface" "general-grob-interface" "beam-interface" "clef-interface" "axis-group-interface" "note-column-interface" "stem-interface" "slur-interface" "side-position-interface" "accidentals-interface" "line-of-score-interface" "note-head-interface" "note-name-interface" "rhythmic-head-interface" "rest-interface" "tuplet-bracket-interface" "align-interface" "aligned-interface" "align-interface" "break-aligned-interface" "chord-name-interface" "time-signature-interface" "bar-line-interface" "hairpin-interface" "arpeggio-interface" "note-collision-interface" "custos-interface" "dot-interface" "font-interface" "text-interface" "dot-column-interface" "dynamic-interface" "finger-interface" "separation-spanner-interface" "text-script-interface" "grace-alignment-interface" "hara-kiri-group-interface" "line-spanner-interface" "lyric-hyphen-interface" "key-signature-interface" "lyric-extender-interface" "lyric-syllable-interface" "mark-interface" "multi-measure-rest-interface" "font-interface" "paper-column-interface" "spaceable-element-interface" "rest-collision-interface" "script-interface" "script-column-interface" "spacing-spanner-interface" "staff-symbol-interface" "stem-tremolo-interface" "separation-item-interface" "sustain-pedal-interface" "system-start-delimiter-interface" "text-spanner-interface" "tie-interface" "tie-column-interface" "volta-bracket-interface"))
+(define (list-interface-names) '("general-grob-interface" "beam-interface" "clef-interface" "axis-group-interface" "note-column-interface" "stem-interface" "slur-interface" "side-position-interface" "accidentals-interface" "line-of-score-interface" "note-head-interface" "note-name-interface" "rhythmic-head-interface" "rest-interface" "tuplet-bracket-interface" "align-interface" "aligned-interface" "break-aligned-interface" "chord-name-interface" "time-signature-interface" "bar-line-interface" "hairpin-interface" "arpeggio-interface" "note-collision-interface" "custos-interface" "dot-interface" "font-interface" "text-interface" "dot-column-interface" "dynamic-interface" "finger-interface" "separation-spanner-interface" "text-script-interface" "grace-alignment-interface" "hara-kiri-group-interface" "line-spanner-interface" "lyric-hyphen-interface" "key-signature-interface" "lyric-extender-interface" "lyric-syllable-interface" "mark-interface" "multi-measure-rest-interface" "paper-column-interface" "spaceable-element-interface" "rest-collision-interface" "script-interface" "script-column-interface" "spacing-spanner-interface" "staff-symbol-interface" "stem-tremolo-interface" "separation-item-interface" "sustain-pedal-interface" "system-start-delimiter-interface" "text-spanner-interface" "tie-interface" "tie-column-interface" "volta-bracket-interface" "span-bar-interface"))
+
 
 (eval-string (ly-gulp-file "interface-description.scm"))
 
 
 (define (document-all-interfaces name)
   (string-append
-   (texi-node-menu name (map (lambda (x) (cons (interface-name x) ""))
+   (texi-node-menu name (map (lambda (x)
+                              (cons (interface-name (symbol->string x)) ""))
                             (map cadr interface-description-alist)))
    (apply string-append
          (map document-separate-interface
index 30dcec73c77b7d158eb74dacbc5a09e65cccdcca..dd863c9b1760c5ee3ab4db359234d84e022cda3a 100644 (file)
@@ -1,4 +1,4 @@
-;;
+;;;
 ;;; documentation-lib.scm -- Assorted Functions for generated documentation
 ;;;
 ;;; source file of the GNU LilyPond music typesetter
@@ -125,7 +125,7 @@ Add a ref if REF is set
    ;; prepend GNU for dir, must be unique
    "\n* GNU " name " (" file-name ").           " name "."
    "\n@end direntry"
-   (node "Top") ",(lilypond)Development,," top
+   (node "Top") ",(lilypond)Features,," top
    "\n@top"
    (texi-section 1 name #f)
    (texi-menu items-alist)
index 12d3100f63ab83efdf8f6b61ea7f6dfa2f08fe7d..bdab2c870e3865775b08d304cf7e2c2c0b33fd34 100644 (file)
 ;; First level Engraver description and
 ;; second level Context description
 (define (document-engraver where engraver-descr)
   (let* (
         (level (if (eq? where 'context) 3 2))
         (props (car (cdddr engraver-descr)))
         (name (car engraver-descr))
+        (name-sym (string->symbol name))
         (desc (cadr engraver-descr))
         (objs (map symbol->string (caddr engraver-descr)))
         )
@@ -60,7 +60,7 @@
                                            (cdr (assoc 'consists x))
                                            (cdr (assoc 'end-consists x)))))
 
-                            (if (member name consists)
+                            (if (member name-sym consists)
                                 (list context)
                                 '())))
                         context-description-alist))))
 
 (define (document-all-engravers name)
   (let* ((descs (map cdr engraver-description-alist))
-        (names (map car engraver-description-alist))
+        (names (map symbol->string (map car engraver-description-alist)))
         (doc (apply string-append
                     (map (lambda (x) (document-separate-engraver name x))
                          descs))))
-    
     (string-append
      (texi-node-menu name (map (lambda (x) (cons (engraver-name x) ""))
                               names))
      doc)))
 
 (define (document-all-engraver-properties name)
-  (let*
-    (
-     (ps (sort (map symbol->string all-translation-properties) string<?))
-     (sortedsyms (map string->symbol ps))
-     (propdescs (map document-translator-property sortedsyms))
-     (texi (description-list->texi propdescs))
-     )
+  (let* ((ps (sort (map symbol->string all-translation-properties) string<?))
+        (sortedsyms (map string->symbol ps))
+        (propdescs (map document-translator-property sortedsyms))
+        (texi (description-list->texi propdescs)))
      
   (string-append
          (node name)
          (texi-section 1 name #f)
-         texi
-   )))
+         texi)))
index 023467173233ed57df1e437cbee33d888101ebed..9e605e9424de07260ef24e03f5e1e09722317926 100644 (file)
@@ -32,7 +32,7 @@
 (let* ((doc (string-append
             (document-paper "LilyPond interpretation contexts")
             (document-all-engravers "LilyPond engravers")
-            (document-all-engraver-properties "LilyPond context properties")        
+            (document-all-engraver-properties "LilyPond context properties")        
             (document-all-grobs "LilyPond backend")
             (document-all-interfaces "LilyPond interfaces")
             (document-all-backend-properties "LilyPond backend properties")
index 4ae22d7a7dfff38d6e6476a0a1cd816fb94c7cb7..caf6363c92f620198af49cad35b5073d41d6fe0e 100644 (file)
@@ -262,7 +262,6 @@ object."
     )
 ))
 
-
 (define align-interface
   (lily-interface
    'align-interface
@@ -772,6 +771,6 @@ direction = Forced direction for all ties"
    '(
     )))
 
-
+;(define urg-miss-last-interface )
 
 
index dc3ee80fcef0d159045a45a233eab510818edf74..c4d75ac23ee92a437fffc16cbe194a20df80ea0e 100644 (file)
@@ -6,7 +6,7 @@
 ;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
 
 (define standalone (not (defined? 'ly-gulp-file)))
-(write standalone (current-error-port))
+;;(write standalone (current-error-port))
 
 (define (gulp-file name)
   (let* ((file (open-input-file name))
@@ -34,4 +34,4 @@
 (define ly-gulp-file scm-gulp-file)
 (define ly-number->string scm-number->string)
 
-(eval-string (ly-gulp-file "lily.scm"))
\ No newline at end of file
+(eval-string (ly-gulp-file "lily.scm"))