]> git.donarmstrong.com Git - lilypond.git/blobdiff - scm/part-combiner.scm
* lily/font-metric.cc (get_encoded_index): New function.
[lilypond.git] / scm / part-combiner.scm
index 99c28ea57746f567af54f0ff8e3d0a333f53b52f..0997a29b8afa2233d825c0f54f8a63904262527f 100644 (file)
@@ -118,7 +118,8 @@ Voice-state objects
     
     (define (analyse-tie-start active ev)
       (if (equal? (ly:music-property ev 'name) 'TieEvent)
-         (acons 'tie index active)
+         (acons 'tie (split-index (vector-ref voice-state-vec index))
+                active)
          active))
     
     (define (analyse-tie-end active ev)
@@ -264,8 +265,15 @@ Only set if not set previously.
                 (if (and (= (length pitches1) (length pitches2)))
                     (if (and (pair? pitches1)
                              (pair? pitches2)
-                             (< chord-threshold (ly:pitch-steps
-                                                 (ly:pitch-diff (car pitches1) (car pitches2)))))
+                             (or
+                              (< chord-threshold (ly:pitch-steps
+                                                  (ly:pitch-diff (car pitches1)
+                                                                 (car pitches2))))
+
+                              ;; voice crossings:
+                              (> 0 (ly:pitch-steps (ly:pitch-diff (car pitches1)
+                                                                  (car pitches2))))
+                              ))
                         (put 'apart)
                         ;; copy previous split state from spanner state
                         (begin
@@ -282,6 +290,8 @@ Only set if not set previously.
          (let* ((now-state (vector-ref result ri))
                 (vs1 (car (voice-states now-state)))
                 (vs2 (cdr (voice-states now-state))))
+
+           
            (cond ((not vs1) (put 'apart))
                  ((not vs2) (put 'apart))
                  (else