]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/text-spanner-engraver.cc
Run `make grand-replace'.
[lilypond.git] / lily / text-spanner-engraver.cc
index 0b9f3e4a67db4463eb7cf372cd525f91d0871839..9c1ebdcf0f0f2a76e565e40c6366c39ca98c63f6 100644 (file)
@@ -3,13 +3,14 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 2000--2007 Jan Nieuwenhuizen <janneke@gnu.org>
+  (c) 2000--2008 Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
 #include "engraver.hh"
 
 #include "international.hh"
 #include "note-column.hh"
+#include "pointer-group-interface.hh"
 #include "side-position-interface.hh"
 #include "spanner.hh"
 #include "stream-event.hh"
@@ -23,6 +24,7 @@ public:
 protected:
   virtual void finalize ();
   DECLARE_TRANSLATOR_LISTENER (text_span);
+  DECLARE_ACKNOWLEDGER (note_column);
   void stop_translation_timestep ();
   void process_music ();
 
@@ -61,6 +63,7 @@ Text_spanner_engraver::process_music ()
       else
        {
          finished_ = span_;
+         announce_end_grob (finished_, SCM_EOL);
          span_ = 0;
          current_event_ = 0;
        }
@@ -121,8 +124,34 @@ Text_spanner_engraver::finalize ()
     }
 }
 
+
+void
+Text_spanner_engraver::acknowledge_note_column (Grob_info info)
+{
+  if (span_) {
+    Pointer_group_interface::add_grob (span_,
+                                      ly_symbol2scm ("note-columns"),
+                                      info.grob());
+    add_bound_item (span_, info.grob ());
+  } else if (finished_) {
+    Pointer_group_interface::add_grob (finished_, ly_symbol2scm ("note-columns"),
+                                      info.grob());
+    add_bound_item (finished_, info.grob ());
+  }
+}
+
+ADD_ACKNOWLEDGER (Text_spanner_engraver, note_column);
+
 ADD_TRANSLATOR (Text_spanner_engraver,
-               /* doc */ "Create text spanner from an event.",
-               /* create */ "TextSpanner",
-               /* read */ "",
-               /* write */ "");
+               /* doc */
+               "Create text spanner from an event.",
+
+               /* create */
+               "TextSpanner ",
+
+               /* read */
+               "",
+
+               /* write */
+               ""
+               );