]> git.donarmstrong.com Git - lilypond.git/blobdiff - scm/c++.scm
* lily/beam.cc (least_squares): Fix asymmetry and scary float
[lilypond.git] / scm / c++.scm
index 5fea3d145d552e52751a2f415bc269bbe043b474..41bd34139e4243869fe608a20859336feafc449a 100644 (file)
 (define (number-or-grob? x)
   (or (ly-grob? x) (number? x))
   )
-        
+
+(define (grob-list? x)
+  (list? x))
+
 (define (moment-pair?  x)
   (and (pair? x)
        (moment? (car x)) (moment? (cdr x))))
@@ -21,9 +24,6 @@
 (define (boolean-or-symbol? x)
   (or (boolean? x) (symbol? x)))
 
-(define (number-or-boolean? x)
-  (or (number? x) (boolean? x)))
-
 (define (number-or-string? x)
   (or (number? x) (string? x)))
 
@@ -39,6 +39,7 @@
    (,number-pair? . "pair of numbers")
    (,ly-input-location? . "input location")   
    (,ly-grob? . "grob (GRaphical OBject)")
+   (,grob-list? . "list of grobs")
    (,duration? . "duration")
    (,pair? . "pair")
    (,integer? . "integer")
@@ -58,7 +59,6 @@
    (,procedure? . "procedure") 
    (,boolean-or-symbol? . "boolean or symbol")
    (,number-or-string? . "number or string")
-   (,number-or-boolean? . "number or boolean")
    (,markup? . "markup (list or string)")
    (,number-or-grob? . "number or grob")
    ))
@@ -136,15 +136,23 @@ is the  first to satisfy CRIT "
   (let*
       ((supported-reps
        `(("volta" . ((iterator-ctor . ,Volta_repeat_iterator::constructor)
+                     (start-moment-function .  ,Repeated_music::first_start)
                      (length . ,Repeated_music::volta_music_length)))
+         
            ("unfold" . ((iterator-ctor . ,Unfolded_repeat_iterator::constructor)
-                      (length . ,Repeated_music::unfolded_music_length)))
+                        (start-moment-function .  ,Repeated_music::first_start)                         
+                        (length . ,Repeated_music::unfolded_music_length)))
            ("fold" . ((iterator-ctor  . ,Folded_repeat_iterator::constructor)
+                      (start-moment-function .  ,Repeated_music::minimum_start)                         
                       (length . ,Repeated_music::folded_music_length)))
            ("percent" . ((iterator-ctor . ,Percent_repeat_iterator::constructor)
+                         (start-moment-function .  ,Repeated_music::first_start)
                          (length . ,Repeated_music::unfolded_music_length)))
            ("tremolo" . ((iterator-ctor . ,Chord_tremolo_iterator::constructor)
-                         (length . ,Repeated_music::unfolded_music_length)))))
+                         (start-moment-function .  ,Repeated_music::first_start)
+
+                         ;; the length of the repeat is handled by shifting the note logs
+                         (length . ,Repeated_music::folded_music_length)))))
          
        (handle (assoc name supported-reps)))