]> git.donarmstrong.com Git - lilypond.git/commitdiff
* input/test/poly-metric.ly: update to use Timing.
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 6 Sep 2002 21:13:31 +0000 (21:13 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 6 Sep 2002 21:13:31 +0000 (21:13 +0000)
* lily/bar-number-engraver.cc (process_music): only run
barNumberVisibility if currentBarNumber is a number.

* lily/parser.yy (chord_inversion): use CHORD_SLASH for '/'
(command_element): use Timing as alias for Score.

ChangeLog
Documentation/user/refman.itely
input/test/poly-metric.ly
lily/bar-number-engraver.cc
lily/parser.yy
ly/engraver-init.ly
ly/property-init.ly

index 91da130e10fa2bf3c6e9fe2c74778bcfb2ea34b2..8c7647c44c9d7e04564b155a96d3e179d89f64ed 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,12 @@
 2002-09-06  Han-Wen Nienhuys  <hanwen@cs.uu.nl>
 
+       * input/test/poly-metric.ly: update to use Timing.
+
+       * lily/bar-number-engraver.cc (process_music): only run
+       barNumberVisibility if currentBarNumber is a number.
+
        * lily/parser.yy (chord_inversion): use CHORD_SLASH for '/'
+       (command_element): use Timing as alias for Score.
 
 2002-09-06  Jérémie Lumbroso  <jeremie@lumbroso.fr>
 
index 05d42eba2e02fb4f813fa7dc0d54b81b808e4713..8ddd5a837d1fed17d4bc5d1d828507bd0a14117c 100644 (file)
@@ -929,7 +929,8 @@ many more options for its layout. They are selected through the
 examples.
 
 This command sets the property @code{timeSignatureFraction},
-@code{beatLength} and @code{measureLength}.  The property
+@code{beatLength} and @code{measureLength} in the @code{Timing}
+context, which is normally aliased to @internalsref{Score}.  The property
 @code{timeSignatureFraction} determine where bar lines should be
 inserted, and how automatic beams should be generated.  Changing the
 value of @code{timeSignatureFraction} also causes a time signature
@@ -957,7 +958,7 @@ The syntax for this command is
 @end example
 This is  internally translated into
 @example
-  \property Score.measurePosition = -@var{length of duration}
+  \property Timing.measurePosition = -@var{length of duration}
 @end example
 @cindex @code{|}
 The property @code{measurePosition} contains a rational number
index 13ea702ef3ce061b3a131f562127ca523dd40c22..7a5b1365654ad5f55a4e881ac9e8fed9ef67c8e6 100644 (file)
@@ -8,19 +8,15 @@
     \notes
     <
        \context Staff = SA
-       { % \time hardcodes \property Score.XXX = YYY
-       \property Staff.timeSignatureFraction = #'(4 . 4)
-       \property Staff.measureLength = #(make-moment 1 1)
-       \property Staff.beatLength = #(make-moment 1 4)
+       {
+           \time 4/4
        c1 c1 c1
-       \property Staff.whichBar = #"|."
+       \bar "|."
     }
-       \context Staff= SB {
-       \property Staff.timeSignatureFraction = #'(3 . 4)
-       \property Staff.measureLength = #(make-moment 3 4)
-       \property Staff.beatLength = #(make-moment 1 4)
+    \context Staff= SB {
+       \time 3/4
        c2. c2.  c2. c2.
-       \property Staff.whichBar = #"|."
+       \bar "|."
     }
 
     >           
@@ -29,6 +25,8 @@
     \translator{ \ScoreContext
     \remove "Timing_engraver" }
     \translator{ \StaffContext
-    \consists "Timing_engraver"}
+    \consists "Timing_engraver"
+    \alias Timing
+}
 }
 }
index 4c6a3503a95f050aa75de519f23d2afa0bec2748..10eb2f45513e9ccc316c0c4948488264d01b4aea 100644 (file)
@@ -54,7 +54,7 @@ Bar_number_engraver::process_music ()
        {
          SCM bn = get_property ("currentBarNumber");
          SCM proc = get_property ("barNumberVisibility");
-         if (to_boolean(gh_call1(proc, bn)))
+         if (gh_number_p (bn) && to_boolean(gh_call1(proc, bn)))
            {
              create_items ();
              // guh.
index 66b2e63568635d1b91480e75bb43ca339436786f..3e92db773553db780a483be08e98b0b4209d618c 100644 (file)
@@ -1224,7 +1224,7 @@ command_element:
                $$ = csm;
                $$->set_spot (THIS->here_input ());
 
-               csm->set_mus_property ("context-type", scm_makfrom0str ("Score"));
+               csm->set_mus_property ("context-type", scm_makfrom0str ("Timing"));
        }
        | PARTIAL duration_length       {
                Moment m = - unsmob_duration ($2)->length_mom ();
@@ -1235,7 +1235,7 @@ command_element:
                scm_gc_unprotect_object (p->self_scm ());
 
                $$ =sp ;
-               sp-> set_mus_property ("context-type", scm_makfrom0str ( "Score"));
+               sp-> set_mus_property ("context-type", scm_makfrom0str ("Timing"));
        }
        | CLEF STRING  {
                SCM func = scm_primitive_eval (ly_symbol2scm ("clef-name-to-properties"));
@@ -1279,8 +1279,6 @@ command_element:
                Context_specced_music * sp = new Context_specced_music (SCM_EOL);
                sp->set_mus_property ("element", seq->self_scm ());
 
-               
-
                scm_gc_unprotect_object (p3->self_scm ());
                scm_gc_unprotect_object (p2->self_scm ());
                scm_gc_unprotect_object (p1->self_scm ());
@@ -1288,11 +1286,7 @@ command_element:
 
                $$ = sp;
 
-/*
- TODO: should make alias TimingContext for Score
-*/
-
-               sp-> set_mus_property ("context-type", scm_makfrom0str ( "Score"));
+               sp-> set_mus_property ("context-type", scm_makfrom0str ( "Timing"));
        }
        ;
 
index 5293c26628f54513b6ae8da65e31b4dbbd5d35e0..78a2fcb664ad7eebd77be096e41a3ceedafb2fb4 100644 (file)
@@ -347,7 +347,13 @@ ScoreContext = \translator {
        
        \consists "Repeat_acknowledge_engraver"
        \consists "Staff_collecting_engraver"
+
+       % move the alias along with the engraver.
+
+       %% TODO? add this alias from Timing_engraver::initialize() ? 
        \consists "Timing_engraver"
+       \alias Timing
+       
        \consists "Output_property_engraver"
        \consists "System_start_delimiter_engraver"
        \consists "Mark_engraver"       
index 0afb1888fbe6ae0a63417332a3dabf5228d06f97..003d54f2de663a7fa44e52572cc15862542c5129 100644 (file)
@@ -66,10 +66,10 @@ tupletBoth = {
 
 
 
-cadenzaOn = \property Score.timing = ##f
+cadenzaOn = \property Timing.timing = ##f
 cadenzaOff = {
-  \property Score.timing = ##t
-  \property Score.measurePosition = #(make-moment 0 1)
+  \property Timing.timing = ##t
+  \property Timing.measurePosition = #(make-moment 0 1)
 }
 
 newpage = {