]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/tie-engraver.cc
release: 1.5.12
[lilypond.git] / lily / tie-engraver.cc
index 283e5aac4d95b746e27eb3bbcfda84c78804c407..d96acb32e973073f031dcc68ed025732e178a6cd 100644 (file)
@@ -164,16 +164,18 @@ Tie_engraver::create_grobs ()
          if (!i)
            return;
          
-         SCM pair = gh_list_ref (head_list, gh_int2scm (i/2));
+         SCM pair = scm_list_ref (head_list, gh_int2scm (i/2));
          
          Spanner * p = new Spanner (basic);
-         Tie::set_head (p,LEFT, dynamic_cast<Item*> (unsmob_grob (gh_car (pair))));
-         Tie::set_head (p,RIGHT, dynamic_cast<Item*> (unsmob_grob (gh_cdr (pair))));
+
+         Tie::set_interface (p);
+         Tie::set_head (p,LEFT, dynamic_cast<Item*> (unsmob_grob (ly_car (pair))));
+         Tie::set_head (p,RIGHT, dynamic_cast<Item*> (unsmob_grob (ly_cdr (pair))));
          
          tie_p_arr_.push (p);
          announce_grob (p, req_l_);
        }
-      else for (SCM s = head_list; gh_pair_p (s); s = gh_cdr (s))
+      else for (SCM s = head_list; gh_pair_p (s); s = ly_cdr (s))
        {
          Grob * p = new Spanner (basic);
          Tie::set_interface (p);
@@ -206,12 +208,18 @@ Tie_engraver::stop_translation_timestep ()
     }
   now_heads_.clear ();
 
+  /*
+    we don't warn for no ties, since this happens naturally when you
+    use skipTypesetting.  */
+  
+#if 0
   if (req_l_ && !tie_p_arr_.size ())
     {
       /* How to shut up this warning, when no notes appeared because
         they were suicided by Thread_devnull_engraver? */
       req_l_->origin ()->warning (_ ("No ties were created!"));
     }
+#endif
   
   for (int i=0; i<  tie_p_arr_.size (); i++)
    {
@@ -302,5 +310,5 @@ int
 CHead_melodic_tuple::time_compare (CHead_melodic_tuple const&h1,
                                   CHead_melodic_tuple const &h2)
 {
-  return (h1.end_ - h2.end_).sign ();
+  return Moment::compare(h1.end_,  h2.end_);
 }