]> git.donarmstrong.com Git - lilypond.git/blobdiff - Documentation/user/rhythms.itely
Merge branch 'master' into nested-bookparts
[lilypond.git] / Documentation / user / rhythms.itely
index e3c9f34f8a8009da0e9a0c9f00ed3a7c91bf8fa2..c64ea779a6f6d78ee9d9b4dc75e6de5e114ea940 100644 (file)
@@ -892,27 +892,8 @@ Mensural time signatures are covered in
 
 @snippets
 
-@c TODO Replace by snippet called "Changing the time signature without affecting the beaming"
-@c      Submitted to LSR 2 Nov 08
-
-The @code{\time} command sets the properties
-@code{timeSignatureFraction}, @code{beatLength}, @code{beatGrouping}
-and @code{measureLength} in the @code{Timing} context, which is
-normally aliased to @code{Score}.  Changing the value of
-@code{timeSignatureFraction} causes the new time signature symbol
-to be printed without changing any of the other properties:
-
-@lilypond[quote,verbatim,relative=2]
-\time 3/4
-a16 a a a a a a a a a a a
-% Change time signature symbol but keep 3/4 beaming
-% due to unchanged underlying time signature
-\set Score.timeSignatureFraction = #'(12 . 16)
-a16 a a a a a a a a a a a
-\time 12/16
-% Lose 3/4 beaming now \time has been changed
-a16 a a a a a a a a a a a
-@end lilypond
+@lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
+{changing-the-time-signature-without-affecting-the-beaming.ly}
 
 @cindex compound time signatures
 @cindex time signature, compound
@@ -1512,59 +1493,8 @@ beats in each group.
 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
 {specifying-context-with-beatgrouping.ly}
 
-
-@c Added to input/new 3 Nov 08
-@c TODO When available, change to:
-@ignore
 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
 {using-beatlength-and-beatgrouping.ly}
-@end ignore
-
-@c start new snippet
-The property @code{measureLength} determines where bar lines
-should be inserted and, with @code{beatLength} and
-@code{beatGrouping}, how automatic beams should be generated
-for beam durations and time signatures for which no beam-ending
-rules are defined.  This example shows several ways of controlling
-beaming by setting these properties.  The explanations are shown
-as comments in the code.
-
-@lilypond[quote,verbatim,relative=2]
-\time 3/4
-% The default in 3/4 time is to beam in three groups
-% each of a quarter note length
-a16 a a a a a a a a a a a
-
-\time 12/16
-% No auto-beaming is defined for 12/16
-a16 a a a a a a a a a a a
-
-\time 3/4
-a16 a a a a a a a a a a a
-% Change time signature symbol, but retain underlying 3/4 beaming
-\set Score.timeSignatureFraction = #'(12 . 16)
-a16 a a a a a a a a a a a
-
-% The 3/4 time default grouping of (1 1 1) and beatLength of 1/8
-% are not consistent with a measureLength of 3/4, so the beams
-% are grouped at beatLength intervals
-\set Score.beatLength = #(ly:make-moment 1 8)
-a16 a a a a a a a a a a a
-
-% Specify beams in groups of (3 3 2 3) 1/16th notes
-% 3+3+2+3=11, and 11*1/16<>3/4, so beatGrouping does not apply,
-% and beams are grouped at beatLength (1/16) intervals
-\set Score.beatLength = #(ly:make-moment 1 16)
-\set Score.beatGrouping = #'(3 3 2 3)
-a16 a a a a a a a a a a a
-
-% Specify beams in groups of (3 4 2 3) 1/16th notes
-% 3+4+2+3=12, and 12*1/16=3/4, so beatGrouping applies
-\set Score.beatLength = #(ly:make-moment 1 16)
-\set Score.beatGrouping = #'(3 4 2 3)
-a16 a a a a a a a a a a a
-@end lilypond
-@c End of snippet
 
 @funindex subdivideBeams
 
@@ -1695,9 +1625,6 @@ staff:
 << {a8 a a a16 a a a a8 a} \\ {f4. f8 f f f} >>
 @end lilypond
 
-@c TODO Add example using Score for multiple staves?
-@c Hmm.  Not sure it works correctly.  Needs more investigation.
-
 @warning{If any unexpected beam behavior occurs, check the default
 automatic beam settings in @file{scm/@/auto@/-beam@/.scm} for
 possible interference, because the beam endings defined there will
@@ -1748,26 +1675,36 @@ a a a a
 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
 {beam-grouping-in-7-8-time.ly}
 
-@ignore
-
-@c TODO Does this example add anything?
+@lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
+{reverting-default-beam-endings.ly}
 
-In this
-example, automatic beams can only end on a dotted quarter note
-@example
-#(override-auto-beam-setting '(end * * * *) 3 8)
-#(override-auto-beam-setting '(end * * * *) 1 2)
-#(override-auto-beam-setting '(end * * * *) 7 8)
-@end example
+@c TODO Convert to snippet called "Beam endings in Score context"
+@c Submitted to LSR 3 Nov 08
 
-In 4/4 time signature, this means that automatic beams could end only on
-3/8 and on the fourth beat of the measure (after 3/4, that is 2 times
-3/8, has passed within the measure).
+Beam-ending rules specified in the Score context apply to all
+staves, but can be modified at both Staff and Voice levels:
 
-@end ignore
-
-@lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
-{reverting-default-beam-endings.ly}
+@lilypond[quote,verbatim,relative=2]
+  \time 5/4
+  % Set default beaming for all staves
+  #(override-auto-beam-setting '(end * * 5 4) 3 8 'Score)
+  #(override-auto-beam-setting '(end * * 5 4) 7 8 'Score)
+  <<
+    \new Staff {
+      c8 c c c c c c c c c
+    }
+    \new Staff {
+      % Modify beaming for just this staff
+      #(override-auto-beam-setting '(end * * 5 4) 6 8 'Staff)
+      #(revert-auto-beam-setting '(end * * 5 4) 7 8 'Staff)
+      c8 c c c c c c c c c
+    }
+    \new Staff {
+      % Inherit beaming from Score context
+      c8 c c c c c c c c c
+    }
+  >>
+@end lilypond
 
 
 @predefined